Picture partitioning method and apparatus

ABSTRACT

A picture partitioning method and apparatus are described. The method includes determining a split mode of a current node, where the current node includes a luma block and a chroma block. The method further includes determining, based on the split mode of the current node and a size of the current node, that the chroma block of the current node is not further split. In accordance with the chroma block of the current node not being further split, the method includes splitting the luma block of the current node based on the split mode of the current node. In accordance with the chroma block of the current node not being further split, the method may be used to split only the luma block of the current node, thereby improving encoding and decoding efficiency, reducing a maximum throughput of a codec, and facilitating implementation of the codec.

CROSS-REFERENCE TO RELATED APPLICATIONS

This application is a continuation of U.S. application Ser. No.17/187,184, filed on Feb. 26, 2021, now U.S. Pat. No.11,323,708, whichis a continuation of International Application No. PCT/CN2019/103094,filed on Aug. 28, 2019, which claims priorities to Chinese PatentApplication No. 201810990466.9, filed on Aug. 28, 2018 and ChinesePatent Application No. 201811116761.8, filed on Sep. 25, 2018 andChinese Patent Application No. 201910183731.7, filed on Mar. 11, 2019and Chinese Patent Application No. 201910191131.5, filed on Mar. 13,2019 and Chinese Patent Application No. 201910173454.1, filed on Mar. 7,2019 and Chinese Patent Application No. 201910219440.9, filed on Mar.21, 2019 and Chinese Patent Application No. 201910696741.0, filed onJul. 30, 2019. All of the aforementioned patent applications are herebyincorporated by reference in their entireties.

TECHNICAL FIELD

This application relates to the field of video coding, and moreaccurately, to a picture partitioning method and apparatus.

BACKGROUND

As internet technologies rapidly develop and people's material andspiritual cultures are increasingly enriched, there are increasingdemands on applications of videos, especially high-definition videos, onthe internet. However, a high-definition video has a quite large amountof data. To transmit the high-definition video on the internet with alimited bandwidth, a problem that needs to be first resolved is encodingand decoding of the video. Video coding is used in a wide range ofdigital video applications, for example, broadcast digital television,video transmission over internet and mobile networks, real-timeconversational applications such as video chat and video conferencing,DVDs and Blu-ray discs, video content acquisition and editing systems,and security applications of camcorders.

Each picture of a video sequence is usually partitioned into a set ofnon-overlapping blocks, and coding is usually performed at a blocklevel. For example, a prediction block is generated through spatial(intra picture) prediction and/or temporal (inter picture) prediction.Correspondingly, a prediction mode may include an intra prediction mode(spatial prediction) and an inter prediction mode (temporal prediction).An intra prediction mode set may include 35 different intra predictionmodes, for example, non-directional modes such as a DC (or average) modeand a planar mode, or directional modes defined in H.265; or may include67 different intra prediction modes, for example, non-directional modessuch as a DC (or average) mode and a planar mode, or directional modesdefined in H.266 under development. The set of inter prediction modesdepends on an available reference picture and another inter predictionparameter, for example, depending on whether the entire referencepicture is used or only a portion of the reference picture is used.

An existing video is generally a color video, and includes a chromacomponent in addition to a luma component. Therefore, in addition toencoding and decoding the luma component, the chroma component alsoneeds to be encoded and decoded. However, encoding and decodingefficiency is comparatively low in a conventional technology.

SUMMARY

Embodiments of this application (or this disclosure) provide a picturepartitioning apparatus and method.

According to a first aspect, an illustrative example of the presentinvention relates to a picture partitioning method. The method isperformed by a video stream decoding or encoding apparatus. The methodincludes: determining a split mode of a current node, where the currentnode includes a luma block and a chroma block; determining, based on thesplit mode of the current node and a size of the current node, that thechroma block of the current node is not further split; and when thechroma block of the current node is not further split, splitting theluma block of the current node based on the split mode of the currentnode.

According to the method in the first aspect, when the chroma block ofthe current node is not further split, only the luma block of thecurrent node can be split, thereby improving encoding and decodingefficiency, reducing a maximum throughput of a codec, and facilitatingimplementation of the codec.

According to a second aspect, an illustrative example of the presentinvention relates to a video stream decoding apparatus, including aprocessor and a memory. The memory stores an instruction, and theinstruction enables the processor to perform the method according to thefirst aspect.

According to a third aspect, an illustrative example of the presentinvention relates to a video stream encoding apparatus, including aprocessor and a memory. The memory stores an instruction, and theinstruction enables the processor to perform the method according to thefirst aspect.

According to a fourth aspect, a computer-readable storage medium isproposed. The computer-readable storage medium stores an instruction;and when the instruction is executed, one or more processors are enabledto encode video data. The instruction enables the one or more processorsto perform the method according to any possible embodiment of the firstaspect.

According to a fifth aspect, an illustrative example of the presentinvention relates to a computer program including program code. When theprogram code is executed on a computer, the method according to anypossible embodiment of the first aspect is performed.

Details of one or more embodiments are described in accompanyingdrawings and the following descriptions. Other features, objects, andadvantages will be apparent from the description, drawings, and claims.

BRIEF DESCRIPTION OF DRAWINGS

To describe the technical solutions in the embodiments of thisapplication or in the background more clearly, the following describesthe accompanying drawings for describing the embodiments of thisapplication or the background.

FIG. 1A is a block diagram of an example of a video coding system forimplementing an illustrative example of the present invention;

FIG. 1B is a block diagram of an example of a video coding systemincluding either or two of an encoder 20 in FIG. 2 and a decoder 30 inFIG. 3;

FIG. 2 is a block diagram showing an example structure of a videoencoder for implementing an illustrative example of the presentinvention;

FIG. 3 is a block diagram showing an example structure of a videodecoder for implementing an illustrative example of the presentinvention;

FIG. 4 is a block diagram illustrating an example of an encodingapparatus or a decoding apparatus;

FIG. 5 is a block diagram illustrating an example of another encodingapparatus or another decoding apparatus;

FIG. 6 shows an example of a sample grid in a YUV format;

FIG. 7A to FIG. 7E show five different split types;

FIG. 8 shows a quadtree plus binary tree split mode;

FIG. 9 is a flowchart of a method according to Embodiment 1 of thepresent invention;

FIG. 10 is a flowchart of step 906 in Embodiment 1 of the presentinvention; and

FIG. 11 shows a flowchart of a method according to Embodiment 3 of thepresent invention.

In the following, identical reference signs represent identical or atleast functionally equivalent features unless otherwise specified.

DESCRIPTION OF EMBODIMENTS

Video coding usually refers to the processing of a sequence of pictures,which form a video or video sequence. The terms “picture”, “frame”, and“image” may be used as synonyms in the field of video coding. Videocoding used in this application (or present disclosure) indicates videoencoding or video decoding. Video coding is performed on a source side,for example by processing (e.g., by compressing) raw video pictures toreduce an amount of data required for representing the video pictures,for more efficient storage and/or transmission. Video decoding isperformed on a destination side, and usually includes inverse processingwhen compared to an encoder to reconstruct the video pictures. “Coding”of video pictures in the embodiments shall be understood as “encoding”or “decoding” of a video sequence. A combination of encoding componentsand decoding components is also referred to as codec (encoding anddecoding).

Each picture of the video sequence is usually partitioned into a set ofnon-overlapping blocks, and coding is usually performed at a blocklevel. In other words, on an encoder side, a video is usually processed,that is, encoded, at a block (which is also referred to as a pictureblock or a video block) level, for example, by using spatial (intrapicture) prediction and/or temporal (inter picture) prediction togenerate a prediction block, subtracting the prediction block from acurrent block (a block currently processed/to be processed) to obtain aresidual block, transforming the residual block and quantizing theresidual block in a transform domain to reduce an amount of data to betransmitted (compressed). On a decoder side, inverse processing comparedto the encoder is applied to an encoded or compressed block toreconstruct a current block for representation. Furthermore, the encoderduplicates a decoder processing loop, so that the encoder and thedecoder generate identical predictions (e.g., intra predictions andinter predictions) and/or reconstructions for processing, that is,coding subsequent blocks.

The term “block” may be a part of a picture or a frame. Key terms aredefined as follows in this application:

A current block is a block that is being processed. For example, inencoding, the current block is a block that is currently being encoded;in decoding, the current block is a block that is being decoded. If thecurrently processed block is a chroma component block, the currentlyprocessed block is referred to as a current chroma block. A luma blockcorresponding to the current chroma block may be referred to as acurrent luma block.

CTU: is the abbreviation of coding tree unit. A picture includes aplurality of CTUs, and one CTU usually corresponds to one square pictureregion, and includes luma samples and chroma samples in the pictureregion (or may include only luma samples, or may include only chromasamples). The CTU further includes syntax elements. These syntaxelements indicate a method about how to split the CTU into at least onecoding unit (CU) and decode each coding unit to obtain a reconstructedpicture.

CU: is the abbreviation of coding unit. A CU usually corresponds to anA×B rectangular region and includes A×B luma samples and chroma samplescorresponding to the luma samples, where A is the width of therectangle, B is the height of the rectangle, and A may be the same as ordifferent from B. Values of A and B are usually integer powers of 2, forexample, 256, 128, 64, 32, 16, 8, and 4. A coding unit may be decodedthrough decoding processing to obtain a reconstructed picture of an A×Brectangular region. The decoding processing usually includes performingprocessing such as prediction, dequantization, and inversetransformation, to generate a predicted picture and a residual. Areconstructed picture is obtained by superimposing the predicted pictureand the residual.

The following describes embodiments of an encoder 20, a decoder 30, anda coding system 10 based on FIG. 1A to FIG. 3.

FIG. 1A is a conceptual or schematic block diagram illustrating anexample of the coding system 10, for example, a video coding system 10that may use technologies of this application (this disclosure). Anencoder 20 (e.g., the video encoder 20) and a decoder 30 (e.g., thevideo decoder 30) of the video coding system 10 represent examples ofdevices that may be configured to perform intra prediction in accordancewith various examples described in this application. As shown in FIG.1A, the coding system 10 includes a source device 12, configured toprovide encoded data 13, for example, an encoded picture 13, to adestination device 14 for decoding the encoded data 13.

The source device 12 includes an encoder 20, and may additionally oroptionally include a picture source 16, a pre-processing unit 18, forexample, a picture pre-processing unit 18, and a communicationsinterface or communications unit 22.

The picture source 16 may include or be any type of picture capturingdevice, for example, for capturing a real-world picture, and/or any typeof device for generating a picture picture or comment (for screencontent encoding, some text on a screen is also considered as a part ofa to-be-encoded picture or image), for example, a computer-graphicsprocessor for generating a computer animated picture, or any type ofother device for obtaining and/or providing a real-world picture, acomputer animated picture (e.g., screen content, or a virtual reality(VR) picture) and/or any combination thereof (e.g., an augmented reality(AR) picture).

A picture can be considered as a two-dimensional array or matrix ofsamples with luma values. A sample in the array may also be referred toas a pixel (short form of picture element) or a pel. A quantity ofsamples in horizontal and vertical directions (or axes) of the array orthe picture defines a size and/or resolution of the picture. Forrepresentation of color, three color components are usually employed, tobe specific, the picture may be represented as or include three samplearrays. In RBG format or color space a picture includes a correspondingred, green and blue sample array. However, in video coding, each pixelis usually represented in a luma/chroma format or a color space. Forexample, YCbCr, which includes a luma component indicated by Y(sometimes L is used instead) and two chroma components indicated by Cband Cr. The luminance (which is luma for short) component Y representsthe brightness or gray level intensity (e.g., like in a gray-scalepicture), while the two chrominance (which is chroma for short)components Cb and Cr represent the chromaticity or color informationcomponents. Accordingly, a picture in YCbCr format includes a lumasample array of luma sample values (Y), and two chroma sample arrays ofchroma values (Cb and Cr). Pictures in RGB format may be converted ortransformed into YCbCr format and vice versa, and the process is alsoknown as color transformation or conversion. If a picture is monochrome,the picture may include only a luma sample array.

The picture source 16 (e.g., a video source 16) may be, for example, acamera for capturing a picture, a memory such as a picture memory,including or storing a previously captured or generated picture, and/orany kind of (internal or external) interface to obtain or receive apicture. The camera may be, for example, a local camera or an integratedcamera integrated in the source device, and the memory may be a localmemory or an integrated memory, for example, integrated in the sourcedevice. The interface may be, for example, an external interface forreceiving a picture from an external video source. The external videosource is, for example, an external picture capturing device such as acamera, an external memory, or an external picture generating device.The external picture generating device is, for example, an externalcomputer-graphics processor, computer or server. The interface may beany type of interface, for example, a wired or wireless interface or anoptical interface, according to any proprietary or standardizedinterface protocol. An interface for obtaining picture data 17 may bethe same interface as the communications interface 22, or may be a partof the communications interface 22.

In distinction to the pre-processing unit 18 and processing performed bythe pre-processing unit 18, the picture or picture data 17 (e.g., videodata 16) may also be referred to as raw picture or raw picture data 17.

The pre-processing unit 18 is configured to: receive the (raw) picturedata 17, and pre-process the picture data 17 to obtain a pre-processedpicture 19 or pre-processed picture data 19. For example, pre-processingperformed by the pre-processing unit 18 may include trimming, colorformat conversion (e.g., conversion from RGB to YCbCr), color tuning,and denoising. It may be understood that the pre-processing unit 18 maybe an optional component.

The encoder 20 (e.g., the video encoder 20) is configured to receive thepre-processed picture data 19 and provide encoded picture data 21(details are further described below, for example, based on FIG. 2 orFIG. 4). In an example, the encoder 20 may be configured to implementEmbodiments 1 to 3.

The communications interface 22 of the source device 12 may beconfigured to: receive the encoded picture data 21, and transmit theencoded picture data 21 to another device, for example, the destinationdevice 14 or any other device, for storage or direct reconstruction, ormay be configured to process the encoded picture data 21 beforecorrespondingly storing the encoded data 13 and/or transmitting theencoded data 13 to another device, where the another device is, forexample, the destination device 14 or any other device for decoding orstorage.

The destination device 14 includes a decoder 30 (e.g., a video decoder30), and may additionally, i.e. optionally, include a communicationsinterface or communications unit 28, a post-processing unit 32, and adisplay device 34.

The communications interface 28 of the destination device 14 isconfigured receive the encoded picture data 21 or the encoded data 13,for example, directly from the source device 12 or from any othersource. The any other source is, for example, a storage device such asan encoded picture data storage device.

The communications interface 22 and the communications interface 28 maybe configured to transmit or receive the encoded picture data 21 or theencoded data 13 over a direct communication link between the sourcedevice 12 and the destination device 14 or over any type of network. Thedirect communication link is, for example, a direct wired or wirelessconnection, and the any type of network is, for example, a wired orwireless network or any combination thereof, or any type of private andpublic networks, or any combination thereof.

The communications interface 22 may be, for example, configured topackage the encoded picture data 21 into an appropriate format, forexample, packets, for transmission over a communication link orcommunication network.

The communications interface 28, forming the counterpart of thecommunications interface 22, may be configured, for example, tode-package the encoded data 13 to obtain the encoded picture data 21.

Both the communications interface 22 and the communications interface 28may be configured as unidirectional communications interfaces, asindicated by an arrow for the encoded data 13 from the source device 12to the destination device 14 in FIG. 1A, or may be configured as abidirectional communications interface, and may be configured, forexample, to send and receive messages to establish a connection, andacknowledge and exchange any other information related to acommunication link and/or data transmission such as encoded picture datatransmission.

The decoder 30 is configured to receive the encoded picture data 21 andprovide decoded picture data 31 or a decoded picture 31 (details arefurther described below, for example, based on FIG. 3 or FIG. 5). In anexample, the decoder 30 may be configured to implement Embodiments 1 to3.

A post-processor 32 of the destination device 14 is configured topost-process the decoded picture data 31 (which is also referred to asreconstructed picture data), for example, the decoded picture 131, toobtain post-processed picture data 33 such as a post-processed picture33. Post-processing performed by the post-processing unit 32 mayinclude, for example, color format conversion (e.g., conversion fromYCbCr to RGB), color correction, trimming, or re-sampling, or any otherprocessing, for example, for preparing the decoded picture data 31 fordisplaying by the display device 34.

The display device 34 of the destination device 14 is configured toreceive the post-processed picture data 33, to display a picture to auser, a viewer, or the like. The display device 34 may be or include anytype of display for presenting a reconstructed picture, for example, anintegrated or external display or monitor. For example, the display mayinclude a liquid crystal display (LCD), an organic light emitting diode(OLED) display, a plasma display, a projector, a micro LED display, aliquid crystal on silicon (LCoS), a digital light processor (DLP), orany type of other display.

Although FIG. 1A depicts the source device 12 and the destination device14 as separate devices, a device embodiment may alternatively includeboth the source device 12 and the destination device 14 orfunctionalities of both the source device 12 and the destination device14, that is, the source device 12 or a corresponding functionality andthe destination device 14 or a corresponding functionality. In such anembodiment, the source device 12 or the corresponding functionality andthe destination device 14 or the corresponding functionality may beimplemented by using same hardware and/or software, separate hardwareand/or software, or any combination thereof.

As will be apparent for a person skilled in the art based on thedescriptions, (exact) division of functionalities of different units orfunctionalities of the source device 12 and/or the destination device 14shown in FIG. 1A may vary depending on an actual device and application.

The encoder 20 (e.g., the video encoder 20) and the decoder 30 (e.g.,the video decoder 30) may be implemented as any one of various propercircuits, for example, one or more microprocessors, a digital signalprocessor (DSP), an application-specific integrated circuit (ASIC), afield-programmable gate array (FPGA), discrete logic, hardware, or anycombination thereof. If the technologies are implemented partially byusing software, a device may store a software instruction in a propernon-transitory computer-readable storage medium and may execute theinstruction by using hardware such as one or more processors, to performthe technologies of this disclosure. Any of the foregoing content(including hardware, software, a combination of hardware and software,and the like) may be considered as one or more processors. The videoencoder 20 and the video decoder 30 each may be included in one or moreencoders or decoders, and either the encoder or the decoder may beintegrated into a part of a combined encoder/decoder (codec) in acorresponding apparatus.

The source device 12 may be referred to as a video encoding device or avideo encoding apparatus. The destination device 14 may be referred toas a video decoding device or a video decoding apparatus. The sourcedevice 12 and the destination device 14 may be examples of a videoencoding device or a video encoding apparatus.

The source device 12 and the destination device 14 may include any of awide range of devices, including any type of handheld or stationarydevice, for example, a notebook or laptop computer, a mobile phone, asmartphone, a tablet or tablet computer, a camera, a desktop computer, aset-top box, a television, a display device, a digital media player, avideo game console, a video streaming device (such as a content serviceserver or a content delivery server), a broadcast receiver device, or abroadcast transmitter device, and may use or not use any type ofoperating system.

In some cases, the source device 12 and the destination device 14 may beequipped for wireless communication. Therefore, the source device 12 andthe destination device 14 may be wireless communications devices.

In some cases, the video coding system 10 shown in FIG. 1A is merely anexample, and the technologies of this application are applicable tovideo coding settings (e.g., video encoding or video decoding) that donot necessarily include any data communication between encoding anddecoding devices. In another example, data may be retrieved from a localmemory, streamed over a network, or the like. The video encoding devicemay encode data and store the data into a memory, and/or the videodecoding device may retrieve the data from the memory and decode thedata. In some examples, encoding and decoding are performed by devicesthat do not communicate with each other but simply encode data to amemory and/or retrieve the data from the memory and decode the data.

It should be understood that for each of the foregoing examplesdescribed with reference to the video encoder 20, the video decoder 30may be configured to perform a reverse process. With respect tosignaling syntax elements, the video decoder 30 can be configured toreceive and parse these syntax elements and decode related video dataaccordingly. In some examples, the video encoder 20 may entropy encodethe syntax elements into an encoded video bitstream. In these examples,the video decoder 30 may parse these syntax elements and decodeassociated video data accordingly.

FIG. 1B is an illustrative diagram of an example of a video codingsystem 40 including an encoder 20 in FIG. 2 and/or a decoder 30 in FIG.3 according to an example embodiment. The system 40 can implement acombination of various technologies of this application. In theillustrated implementation, the video coding system 40 may include animaging device 41, the video encoder 20, the video decoder 30 (and/or avideo encoder/decoder implemented by a logic circuit 47 of a processingunit 46), an antenna 42, one or more processors 43, one or more memories44, and/or a display device 45.

As shown in the figure, the imaging device 41, the antenna 42, theprocessing unit 46, the logic circuit 47, the video encoder 20, thevideo decoder 30, the processor 43, the memory 44, and/or the displaydevice 45 can communicate with each other. As described, although thevideo coding system 40 is illustrated by using the video encoder 20 andthe video decoder 30, in another different example, the video codingsystem 40 may include only the video encoder 20 or only the videodecoder 30.

In some examples, as shown in the figure, the video coding system 40 mayinclude the antenna 42. For example, the antenna 42 may be configured totransmit or receive an encoded bitstream of video data. In addition, insome examples, the video coding system 40 may include the display device45. The display device 45 may be configured to present the video data.In some examples, as shown in the figure, the logic circuit 47 may beimplemented by the processing unit 46. The processing unit 46 mayinclude application-specific integrated circuit (ASIC) logic, a graphicsprocessor, a general-purpose processor, or the like. The video codingsystem 40 may also include the optional processor 43. The optionalprocessor 43 may similarly include application-specific integratedcircuit (ASIC) logic, a graphics processor, a general-purpose processor,or the like. In some examples, the logic circuit 47 may be implementedby hardware, for example, video coding dedicated hardware, and processor43 may be implemented by general purpose software, an operating system,or the like. In addition, the memory 44 may be any type of memory, forexample, a volatile memory (e.g., a static random access memory (SRAM)or a dynamic random access memory (DRAM)), or a nonvolatile memory(e.g., a flash memory). In a non-limitative example, the memory 44 maybe implemented by a cache memory. In some examples, the logic circuit 47may access the memory 44 (e.g., for implementation of a picture buffer).In other examples, the logic circuit 47 and/or the processing unit 46may include a memory (e.g., a cache) for implementation of a picturebuffer or the like.

In some examples, the video encoder 20 implemented by the logic circuitmay include a picture buffer (which is, for example, implemented by theprocessing unit 46 or the memory 44) and a graphics processing unit(which is, for example, implemented by the processing unit 46). Thegraphics processing unit may be communicatively coupled to the picturebuffer. The graphics processing unit may include the video encoder 20implemented by the logic circuit 47, to implement various modules thatare described with reference to FIG. 2 and/or any other encoder systemor subsystem described in this specification. The logic circuit may beconfigured to perform various operations described in thisspecification.

The video decoder 30 may be implemented in a similar manner asimplemented by the logic circuit 47 to embody the various modules asdiscussed with respect to a decoder 30 in FIG. 3 and/or any otherdecoder system or subsystem described in this specification. In someexamples, the video decoder 30 implemented by the logic circuit mayinclude a picture buffer (which is, for example, implemented by aprocessing unit 2820 or the memory 44) and a graphics processing unit(which is, for example, implemented by the processing unit 46). Thegraphics processing unit may be communicatively coupled to the picturebuffer. The graphics processing unit may include the video decoder 30implemented by the logic circuit 47, to implement various modules thatare described with reference to FIG. 3 and/or any other decoder systemor subsystem described in this specification.

In some examples, the antenna 42 of the video coding system 40 may beconfigured to receive an encoded bitstream of video data. As described,the encoded bitstream may include data, an indicator, an index value,mode selection data, or the like that is related to video frame encodingand that is described in this specification, for example, data relatedto coding partitioning (e.g., a transform coefficient or a quantizedtransform coefficient, an optional indicator (as described), and/or datadefining coding partitioning). The video coding system 40 may furtherinclude the video decoder 30 that is coupled to the antenna 42 and thatis configured to decode the encoded bitstream. The display device 45 isconfigured to present a video frame.

Encoder & Encoding Method

FIG. 2 is a schematic/conceptual block diagram of an example of a videoencoder 20 configured to implement a technology (disclosed) in thisapplication. In the example of FIG. 2, the video encoder 20 includes aresidual calculation unit 204, a transform processing unit 206, aquantization unit 208, an inverse quantization unit 210, an inversetransform processing unit 212, a reconstruction unit 214, a buffer 216,a loop filter unit 220, a decoded picture buffer (DPB) 230, a predictionprocessing unit 260, and an entropy encoding unit 270. The predictionprocessing unit 260 may include an inter prediction unit 244, an intraprediction unit 254, and a mode selection unit 262. The inter predictionunit 244 may include a motion estimation unit and a motion compensationunit (which is not shown in the diagram). The video encoder 20 shown inFIG. 2 may also be referred to as a hybrid video encoder or a videoencoder based on a hybrid video codec.

For example, the residual calculation unit 204, the transform processingunit 206, the quantization unit 208, the prediction processing unit 260,and the entropy encoding unit 270 form a forward signal path of theencoder 20, whereas, for example, the inverse quantization unit 210, theinverse transform processing unit 212, the reconstruction unit 214, thebuffer 216, the loop filter 220, the decoded picture buffer (DPB) 230,and the prediction processing unit 260 form a backward signal path ofthe encoder, where the backward signal path of the video encodercorresponds to a signal path of a decoder (refer to a decoder 30 in FIG.3).

The encoder 20 receives, for example, via an input 202, a picture 201 ora block 203 of a picture 201, for example, a picture in a sequence ofpictures forming a video or a video sequence. The picture block 203 mayalso be referred to as a current picture block or a to-be-encodedpicture block, and the picture 201 may be referred to as a currentpicture or a to-be-encoded picture (particularly in video coding, todistinguish the current picture from other pictures, for example,previously encoded and/or decoded pictures in a same video sequence,namely, the video sequence which also includes the current picture).

Partitioning

In an embodiment, the encoder 20 may include a partitioning unit (whichis not depicted in FIG. 2) configured to partition the picture 201 intoa plurality of blocks such as blocks 203. The picture 201 is usuallypartitioned into a plurality of non-overlapping blocks. The partitioningunit may be configured to: use a same block size for all pictures of avideo sequence and a corresponding grid defining the block size, or tochange a block size between pictures or subsets or groups of pictures,and partition each picture into corresponding blocks.

In an example, the prediction processing unit 260 of the video encoder20 may be configured to perform any combination of the foregoingpartitioning technologies.

Like the picture 201, the block 203 is also or may be considered as atwo-dimensional array or matrix of samples with luma values (samplevalues), although a size of the block 203 is less than a size of thepicture 201. In other words, the block 203 may include, for example, onesample array (e.g., a luma array in a case of a monochrome picture 201),three sample arrays (e.g., one luma array and two chroma arrays in acase of a color picture), or any other quantity and/or type of arraysdepending on an applied color format. A quantity of samples inhorizontal and vertical directions (or axes) of the block 203 define asize of the block 203.

The encoder 20 shown in FIG. 2 is configured to encode the picture 201block by block, for example, encoding and predicting each block 203.

Residual Calculation

The residual calculation unit 204 is configured to calculate a residualblock 205 based on the picture block 203 and a prediction block 265(details about the prediction block 265 are further provided below), forexample, by subtracting sample values of the prediction block 265 fromsample values of the picture block 203 sample by sample (pixel bypixel), to obtain the residual block 205 in a sample domain.

Transform

The transform processing unit 206 is configured to apply a transform,for example, a discrete cosine transform (DCT) or a discrete sinetransform (DST), to sample values of the residual block 205 to obtaintransform coefficients 207 in a transform domain. The transformcoefficients 207 may also be referred to as transform residualcoefficients and represent the residual block 205 in the transformdomain.

The transform processing unit 206 may be configured to apply integerapproximations of DCT/DST, such as transforms specified in HEVC/H.265.Compared with an orthogonal DCT transform, such integer approximationsare usually scaled by a specific factor. To preserve a norm of aresidual block which is processed by using forward and inversetransforms, an additional scaling factor is applied as a part of thetransform process. The scaling factor is usually chosen based on someconstraints, for example, the scaling factor being a power of two for ashift operation, bit depth of the transform coefficients, and a tradeoffbetween accuracy and implementation costs. For example, a specificscaling factor is specified for the inverse transform by, for example,the inverse transform processing unit 212 on a side of the decoder 30(and a corresponding inverse transform by, for example, the inversetransform processing unit 212 on a side of the encoder 20), andcorrespondingly, a corresponding scale factor may be specified for theforward transform by the transform processing unit 206 on a side of theencoder 20.

Quantization

The quantization unit 208 is configured to quantize the transformcoefficients 207 to obtain quantized transform coefficients 209, forexample, by applying scalar quantization or vector quantization. Thequantized transform coefficients 209 may also be referred to asquantized residual coefficients 209. A quantization process can reduce abit depth related to some or all of the transform coefficients 207. Forexample, an n-bit transform coefficient may be rounded down to an m-bittransform coefficient during quantization, where n is greater than m. Aquantization degree may be modified by adjusting a quantizationparameter (QP). For example, for scalar quantization, different scalingmay be applied to achieve finer or coarser quantization. A smallerquantization step size corresponds to finer quantization, and a largerquantization step size corresponds to coarser quantization. Anappropriate quantization step size may be indicated by a quantizationparameter (QP). For example, the quantization parameter may be an indexto a predefined set of appropriate quantization step sizes. For example,a smaller quantization parameter may correspond to finer quantization (asmaller quantization step size), and a larger quantization parameter maycorrespond to coarser quantization (a larger quantization step size), orvice versa. The quantization may include division by a quantization stepsize and corresponding quantization or inverse quantization, forexample, performed by the inverse quantization unit 210, or may includemultiplication by a quantization step size. Embodiments according tosome standards such as HEVC may use a quantization parameter todetermine the quantization step size. Generally, the quantization stepsize may be calculated based on a quantization parameter by using afixed point approximation of an equation including division. Additionalscaling factors may be introduced for quantization and dequantization torestore the norm of the residual block, which may get modified becauseof scaling used in the fixed point approximation of the equation for thequantization step size and the quantization parameter. In one exampleimplementation, scaling of the inverse transform and dequantization maybe combined. Alternatively, customized quantization tables may be usedand signaled from an encoder to a decoder, for example, in a bitstream.The quantization is a lossy operation, where the loss increases withincreasing quantization step sizes.

The inverse quantization unit 210 is configured to apply inversequantization of the quantization unit 208 on quantized coefficients toobtain dequantized coefficients 211, for example, apply, based on or byusing a same quantization step size as the quantization unit 208, theinverse of a quantization scheme applied by the quantization unit 208.The dequantized coefficients 211 may also be referred to as dequantizedresidual coefficients 211 and correspond to the transform coefficients207, although usually not identical to the transform coefficients due tothe loss caused by quantization.

The inverse transform processing unit 212 is configured to apply aninverse transform of the transform applied by the transform processingunit 206, for example, an inverse discrete cosine transform (DCT) or aninverse discrete sine transform (DST), to obtain an inverse transformblock 213 in the sample domain. The inverse transform block 213 may alsobe referred to as an inverse transform dequantized block 213 or aninverse transform residual block 213.

The reconstruction unit 214 (e.g., a summer 214) is configured to addthe inverse transform block 213 (that is, the reconstructed residualblock 213) to the prediction block 265, for example, by adding samplevalues of the reconstructed residual block 213 and the sample values ofthe prediction block 265, to obtain a reconstructed block 215 in thesample domain.

Optionally, a buffer unit 216 (or “buffer” 216 for short) of, forexample, the line buffer 216, is configured to buffer or store thereconstructed block 215 and a corresponding sample value, for example,for intra prediction. In other embodiments, the encoder may beconfigured to use an unfiltered reconstructed block and/or acorresponding sample value stored in the buffer unit 216 for any type ofestimation and/or prediction, for example, intra prediction.

For example, in an embodiment, the encoder 20 may be configured so thatthe buffer unit 216 is not only used for storing the reconstructed block215 for intra prediction 254 but also used for the loop filter unit 220(which is not shown in FIG. 2), and/or so that, for example, the bufferunit 216 and the decoded picture buffer unit 230 form one buffer. Inother embodiments, filtered blocks 221 and/or blocks or samples from thedecoded picture buffer 230 (the blocks or samples are not shown in FIG.2) are used as an input or a basis for intra prediction 254.

The loop filter unit 220 (or “loop filter” 220 for short) is configuredto filter the reconstructed block 215 to obtain a filtered block 221, tosmooth pixel transitions or improve video quality. The loop filter unit220 is intended to represent one or more loop filters such as adeblocking filter, a sample-adaptive offset (SAO) filter, or anotherfilter such as a bilateral filter, an adaptive loop filter (ALF), asharpening or smoothing filter, or a collaborative filter. Although theloop filter unit 220 is shown as an in-loop filter in FIG. 2, in anotherconfiguration, the loop filter unit 220 may be implemented as apost-loop filter. The filtered block 221 may also be referred to as afiltered reconstructed block 221. The decoded picture buffer 230 maystore the reconstructed encoded blocks after the loop filter unit 220performs filtering operations on the reconstructed encoded blocks.

In an embodiment, the encoder 20 (correspondingly, the loop filter unit220) may be configured to output loop filter parameters (such as sampleadaptive offset information), for example, directly or after entropyencoding performed by the entropy encoding unit 270 or any other entropyencoding unit, so that, for example, the decoder 30 can receive the sameloop filter parameters and apply the same loop filter parameters fordecoding.

The decoded picture buffer (DPB) 230 may be a reference picture memorythat stores reference picture data for use in video data encoding by thevideo encoder 20. The DPB 230 may be formed by any one of a variety ofmemory devices such as a dynamic random access memory (DRAM) (includinga synchronous DRAM (SDRAM), a magnetoresistive RAM (MRAM), a resistiveRAM (RRAM)), or other types of memory devices. The DPB 230 and thebuffer 216 may be provided by a same memory device or separate memorydevices. In an example, the decoded picture buffer (DPB) 230 isconfigured to store the filtered block 221. The decoded picture buffer230 may be further configured to store other previously filtered blocks,for example, previously reconstructed and filtered blocks 221, of thesame current picture or of different pictures, for example, previouslyreconstructed pictures, and may provide complete previouslyreconstructed, that is, decoded pictures (and corresponding referenceblocks and samples) and/or a partially reconstructed current picture(and corresponding reference blocks and samples), for example, for interprediction. In an example, if the reconstructed block 215 isreconstructed without in-loop filtering, the decoded picture buffer(DPB) 230 is configured to store the reconstructed block 215.

The prediction processing unit 260, also referred to as a blockprediction processing unit 260, is configured to receive or obtain thepicture block 203 (a current block 203 of the current picture 201) andreconstructed picture data, for example, reference samples of the same(current) picture from the buffer 216 and/or reference picture data 231of one or more previously decoded pictures from the decoded picturebuffer 230, and process such data for prediction, to be specific, toprovide the prediction block 265 that may be an inter prediction block245 or an intra prediction block 255.

The mode selection unit 262 may be configured to select a predictionmode (e.g., an intra or inter prediction mode) and/or a correspondingprediction block 245 or 255 to be used as the prediction block 265, forcalculation of the residual block 205 and for reconstruction of thereconstructed block 215.

In an embodiment, the mode selection unit 262 may be configured toselect the prediction mode (e.g., from prediction modes supported by theprediction processing unit 260). The prediction mode provides a bestmatch or in other words a minimum residual (the minimum residual meansbetter compression for transmission or storage), or provides minimumsignaling overheads (the minimum signaling overheads mean bettercompression for transmission or storage), or considers or balances both.The mode selection unit 262 may be configured to determine theprediction mode based on rate-distortion optimization (RDO), that is,select a prediction mode that provides minimum rate-distortionoptimization or select a prediction mode for which related ratedistortion at least satisfies a prediction mode selection criterion.

In the following, prediction processing performed (e.g., by using theprediction processing unit 260) and mode selection performed (e.g., byusing the mode selection unit 262) by an example of the encoder 20 aredescribed in more detail.

As described above, the encoder 20 is configured to determine or selecta best prediction mode or an optimal prediction mode from a set of(pre-determined) prediction modes. The set of prediction modes mayinclude, for example, intra prediction modes and/or inter predictionmodes.

The intra prediction mode set may include 35 different intra predictionmodes, or may include 67 different intra prediction modes, or mayinclude an intra prediction mode defined in H.266 that is beingdeveloped.

The set of inter prediction modes depends on an available referencepicture (that is, at least a part of the decoded picture stored in theDBP 230) and another inter prediction parameter, for example, dependingon whether the entire reference picture is used or only a part of thereference picture is used, for example, a search window region around aregion of the current block, to search for a best matching referenceblock, and/or depending, for example, on whether pixel interpolationsuch as half-pixel and/or quarter-pixel interpolation is applied.

Additional to the above prediction modes, a skip mode and/or a directmode may be applied.

The prediction processing unit 260 may be further configured to splitthe block 203 into smaller block partitions or sub-blocks, for example,by iteratively using quadtree (QT) partitioning, binary-tree (BT)partitioning, ternary-tree (TT) partitioning, or any combinationthereof, and to perform, for example, prediction for each of the blockpartitions or sub-blocks. Mode selection includes selection of a treestructure of the partitioned block 203 and selection of a predictionmode applied to each of the block partitions or sub-blocks.

The inter prediction unit 244 may include a motion estimation (ME) unit(which is not shown in FIG. 2) and a motion compensation (MC) unit(which is not shown in FIG. 2). The motion estimation unit is configuredto receive or obtain the picture block 203 (the current picture block203 of the current picture 201) and a decoded picture 231, or at leastone or more previously reconstructed blocks, for example, one or morereconstructed blocks of other/different previously decoded pictures 231,for motion estimation. For example, a video sequence may include thecurrent picture and the previously decoded pictures 31. In other words,the current picture and the previously decoded pictures 31 may be a partof or form a sequence of pictures forming the video sequence.

For example, the encoder 20 may be configured to select a referenceblock from a plurality of reference blocks of a same picture ordifferent pictures of a plurality of other pictures and provide, to themotion estimation unit (which is not shown in FIG. 2), a referencepicture and/or an offset (a spatial offset) between a position(coordinates X and Y) of the reference block and a position of thecurrent block as an inter prediction parameter. This offset is alsoreferred to as a motion vector (MV).

The motion compensation unit is configured to obtain, for example,receive, the inter prediction parameters and to perform inter predictionbased on or by using the inter prediction parameters to obtain an interprediction block 245. Motion compensation performed by the motioncompensation unit (which is not shown in FIG. 2) may include fetching orgenerating the prediction block based on a motion/block vectordetermined through motion estimation (possibly by performinginterpolations in sub-pixel precision). Interpolation filtering maygenerate additional pixel samples from known pixel samples, therebypotentially increasing a quantity of candidate prediction blocks thatmay be used to code a picture block. Upon receiving a motion vector fora PU of the current picture block, the motion compensation unit 246 maylocate a prediction block to which the motion vector points in one ofthe reference picture lists. The motion compensation unit 246 may alsogenerate syntax elements associated with the blocks and video slices foruse by video decoder 30 in decoding the picture blocks of the videoslice.

The intra prediction unit 254 is configured to obtain, for example,receive, a picture block 203 (the current picture block) and one or morepreviously reconstructed blocks, for example, reconstructed neighboringblocks, of a same picture for intra estimation. The encoder 20 may be,for example, configured to select an intra prediction mode from aplurality of (predetermined) intra prediction modes.

In an embodiment, the encoder 20 may be configured to select an intraprediction mode based on an optimization criterion, for example, basedon a minimum residual (e.g., an intra prediction mode providing theprediction block 255 that is most similar to the current picture block203) or minimum rate distortion.

The intra prediction unit 254 is further configured to determine theintra prediction block 255 based on, for example, intra predictionparameters in the selected intra prediction mode. In any case, afterselecting an intra prediction mode of a block, the intra prediction unit254 is further configured to provide intra prediction parameters, thatis, information indicating the selected intra prediction mode of theblock, to the entropy encoding unit 270. In an example, the intraprediction unit 254 may be configured to perform any combination ofintra prediction technologies described below.

The entropy encoding unit 270 is configured to apply (or not apply) anentropy encoding algorithm or scheme (e.g., a variable-length coding(VLC) scheme, a context adaptive VLC (CAVLC) scheme, an arithmeticcoding scheme, context adaptive binary arithmetic coding (CABAC),syntax-based context-adaptive binary arithmetic coding (SBAC),probability interval partitioning entropy (PIPE) coding, or anotherentropy encoding methodology or technology) to one or all of thequantized residual coefficients 209, the inter prediction parameters,the intra prediction parameters, and/or the loop filter parameters, toobtain encoded picture data 21 that may be output via an output 272, forexample, in a form of an encoded bitstream 21. The encoded bitstream maybe transmitted to the video decoder 30, or archived for latertransmission or retrieval by the video decoder 30. The entropy encodingunit 270 may be further configured to entropy encode other syntaxelements for a current video slice being encoded.

Other structural variations of the video encoder 20 can be used toencode a video stream. For example, a non-transform based encoder 20 mayquantize a residual signal directly without the transform processingunit 206 for some blocks or frames. In another implementation, theencoder 20 may have the quantization unit 208 and the inversequantization unit 210 combined into a single unit.

FIG. 3 shows an example of a video decoder 30, configured to implement atechnology of this application. The video decoder 30 is configured toreceive encoded picture data (e.g., an encoded bitstream) 21 encoded by,for example, an encoder 20, to obtain a decoded picture 231. In adecoding process, the video decoder 30 receives video data from thevideo encoder 20, for example, an encoded video bitstream thatrepresents a picture block of an encoded video slice and associatedsyntax elements.

In the example of FIG. 3, the decoder 30 includes an entropy decodingunit 304, an inverse quantization unit 310, an inverse transformprocessing unit 312, a reconstruction unit 314 (e.g., a summer 314), abuffer 316, a loop filter 320, a decoded picture buffer 330, and aprediction processing unit 360. The prediction processing unit 360 mayinclude an inter prediction unit 344, an intra prediction unit 354, anda mode selection unit 362. In some examples, the video decoder 30 mayperform a decoding pass generally reciprocal to the encoding passdescribed with reference to the video encoder 20 in FIG. 2.

The entropy decoding unit 304 is configured to perform entropy decodingon the encoded picture data 21 to obtain, for example, quantizedcoefficients 309 and/or decoded coding parameters (which are not shownin FIG. 3), for example, any one or all of an inter predictionparameters, intra prediction parameters, loop filter parameters, and/orother syntax elements (that are decoded). The entropy decoding unit 304is further configured to forward the inter prediction parameters, theintra prediction parameters, and/or the other syntax elements to theprediction processing unit 360. The video decoder 30 may receive syntaxelements at a video slice level and/or a video block level.

The inverse quantization unit 310 may have a same function as theinverse quantization unit 110, the inverse transform processing unit 312may have a same function as the inverse transform processing unit 212,the reconstruction unit 314 may have a same function as thereconstruction unit 214, the buffer 316 may have a same function as thebuffer 216, the loop filter 320 may have a same function as the loopfilter 220, and the decoded picture buffer 330 may have a same functionas the decoded picture buffer 230.

The prediction processing unit 360 may include the inter prediction unit344 and the intra prediction unit 354. The inter prediction unit 344 maybe similar to the inter prediction unit 244 in function, and the intraprediction unit 354 may be similar to the intra prediction unit 254 infunction. The prediction processing unit 360 is usually configured toperform block prediction and/or obtain a prediction block 365 from theencoded data 21, and receive or obtain (explicitly or implicitly)prediction-related parameters and/or information about a selectedprediction mode, for example, from the entropy decoding unit 304.

When the video slice is coded as an intra coded (I) slice, the intraprediction unit 354 of the prediction processing unit 360 is configuredto generate the prediction block 365 for a picture block of the currentvideo slice based on a signaled intra prediction mode and data that isfrom previously decoded blocks of a current frame or picture. When thevideo frame is coded as an inter coded (that is, B or P) slice, theinter prediction unit 344 (e.g., a motion compensation unit) of theprediction processing unit 360 is configured to generate a predictionblocks 365 for a video block of the current video slice based on amotion vector and the other syntax elements received from the entropydecoding unit 304. For inter prediction, the prediction block may begenerated from one of the reference pictures in one of the referencepicture lists. The video decoder 30 may construct reference frame lists,a list 0 and a list 1, by using default construction technologies basedon reference pictures stored in the DPB 330.

The prediction processing unit 360 is configured to determine predictioninformation for a video block of the current video slice by parsing themotion vector and the other syntax elements, and use the predictioninformation to generate the prediction block for the current video blockbeing decoded. For example, the prediction processing unit 360 uses someof the received syntax elements to determine a prediction mode (e.g.,intra or inter prediction) used to code the video blocks of the videoslice, an inter prediction slice type (e.g., a B slice, a P slice, or aGPB slice), construction information for one or more of the referencepicture lists for the slice, motion vectors for each inter encoded videoblock of the slice, an inter prediction status for each inter codedvideo block of the slice, and other information to decode the videoblocks in the current video slice.

The inverse quantization unit 310 may be configured to inverse quantize(that is, dequantize) quantized transform coefficients provided in thebitstream and decoded by the entropy decoding unit 304. An inversequantization process may include: using quantization parameterscalculated by the video encoder 20 for each video block in the videoslice, to determine a quantization degree that should be applied and,likewise, an inverse quantization degree that should be applied.

The inverse transform processing unit 312 is configured to apply aninverse transform (e.g., an inverse DCT, an inverse integer transform,or a conceptually similar inverse transform process) to transformcoefficients, to generate a residual block in a pixel domain.

The reconstruction unit 314 (e.g., the summer 314) is configured to addan inverse transform block 313 (namely, a reconstructed residual block313) to the prediction block 365, for example, by adding sample valuesof the reconstructed residual block 313 and sample values of theprediction block 365, to obtain a reconstructed block 315 in a sampledomain.

The loop filter unit 320 (in a coding loop or after a coding loop) isconfigured to filter the reconstructed block 315 to obtain a filteredblock 321, to smooth pixel transitions or improve video quality. In anexample, the loop filter unit 320 may be configured to perform anycombination of filtering technologies described below. The loop filterunit 320 is intended to represent one or more loop filters such as adeblocking filter, a sample-adaptive offset (SAO) filter, or anotherfilter such as a bilateral filter, an adaptive loop filter (ALF), asharpening or smoothing filter, or a collaborative filter. Although theloop filter unit 320 is shown as an in-loop filter in FIG. 3, in anotherconfiguration, the loop filter unit 320 may be implemented as apost-loop filter.

The decoded video blocks 321 in a given frame or picture are then storedin the decoded picture buffer 330 that stores reference pictures usedfor subsequent motion compensation.

The decoder 30 is configured to, for example, output the decoded picture31 via an output 332, for presentation to a user or viewing by a user.

Other variations of the video decoder 30 may be configured to decode acompressed bitstream. For example, the decoder 30 may generate an outputvideo stream without the loop filter unit 320. For example, anon-transform based decoder 30 may inversely quantize a residual signaldirectly without the inverse transform processing unit 312 for someblocks or frames. In another implementation, the video decoder 30 mayhave the inverse quantization unit 310 and the inverse transformprocessing unit 312 combined into a single unit.

FIG. 4 is a schematic structural diagram of a video coding device 400(e.g., a video encoding device 400 or a video decoding device 400)according to an embodiment of the present invention. The video codingdevice 400 is suitable for implementing the embodiments described inthis specification. In an embodiment, the video coding device 400 may bea video decoder (e.g., the video decoder 30 in FIG. 1A) or a videoencoder (e.g., the video encoder 20 in FIG. 1A).). In anotherembodiment, the video coding device 400 may be one or more components inthe video decoder 30 in FIG. 1A or the video encoder 20 in FIG. 1A.

The video coding device 400 includes ingress ports 410 and a receiverunit (Rx) 420 that are for receiving data; a processor, a logic unit, ora central processing unit (CPU) 430 for processing the data; atransmitter unit (Tx) 440 and egress ports 450 that are for transmittingthe data; and a memory 460 for storing the data. The video coding device400 may also include optical-to-electrical components andelectrical-to-optical (EO) components that are coupled to the ingressports 410, the receiver unit 420, the transmitter unit 440, and theegress ports 450, for egress or ingress of optical or electricalsignals.

The processor 430 is implemented by hardware and software. The processor430 may be implemented as one or more CPU chips, cores (e.g., amulti-core processor), FPGAs, ASICs, and DSPs. The processor 430communicates with the ingress ports 410, the receiver unit 420, thetransmitter unit 440, the egress ports 450, and the memory 460. Theprocessor 430 includes a coding module 470 (e.g., an encoding module 470or a decoding module 470). The encoding/decoding module 470 implementsthe foregoing disclosed embodiments. For example, the encoding/decodingmodule 470 performs, processes, or provides various coding operations.Therefore, the encoding/decoding module 470 provides a substantialimprovement to the functionality of the video coding device 400 andaffects transform of the video coding device 400 to a different state.Alternatively, the encoding/decoding module 470 is implemented asinstructions stored in the memory 460 and executed by the processor 430.

The memory 460 includes one or more disks, tape drives, and solid-statedrives and may be used as an over-flow data storage device, to storeprograms when these programs are selected for execution, and to storeinstructions and data that are read during program execution. The memory460 may be volatile and/or nonvolatile, and may be a read-only memory(ROM), a random access memory (RAM), a ternary content-addressablememory (TCAM), and/or a static random access memory (SRAM).

FIG. 5 is a simplified block diagram of an apparatus 500 that may beused as either or two of the source device 12 and the destination device14 in FIG. 1A according to an example embodiment. The apparatus 500 mayimplement the technology of this application. The apparatus 500 forimplementing picture partitioning may be in a form of a computing systemincluding a plurality of computing devices, or in a form of a singlecomputing device such as a mobile phone, a tablet computer, a laptopcomputer, or a desktop computer.

A processor 502 of the apparatus 500 may be a central processing unit.Alternatively, a processor 502 may be any other type of device or aplurality of devices that can control or process information and thatare existing or to be developed in the future. As shown in the figure,although the disclosed implementations can be practiced with a singleprocessor such as the processor 502, advantages in speed and efficiencycan be achieved by using more than one processor.

In an implementation, a memory 504 of the apparatus 500 can be a readonly memory (ROM) device or a random access memory (RAM) device. Anyother appropriate type of storage device can be used as the memory 504.The memory 504 can include code and data 506 that is accessed by theprocessor 502 by using a bus 512. The memory 504 can further include anoperating system 508 and application programs 510. The applicationprograms 510 include at least one program that allows the processor 502to perform the methods described in this specification. For example, theapplication programs 510 may include applications 1 to N, and theapplications 1 to N further include a video coding application thatperforms the method described in this specification. The apparatus 500may also include an additional memory in a form of a secondary storage514. The secondary storage 514 may be, for example, a memory card usedwith a mobile computing device. Because the video communication sessionsmay contain a large amount of information, these information can bestored in whole or in part in the secondary storage 514 and loaded intothe memory 504 as needed for processing.

The apparatus 500 can also include one or more output devices, such as adisplay 518. In an example, the display 518 may be a touch sensitivedisplay that combines a display with a touch sensitive element that isoperable to sense touch inputs. The display 518 can be coupled to theprocessor 502 by using the bus 512. Other output devices that allow auser to program or otherwise use the apparatus 500 can be provided inaddition to or as an alternative to the display 518. When the outputdevice is or includes a display, the display can be implemented indifferent ways, including by a liquid crystal display (LCD), acathode-ray tube (CRT) display, a plasma display or light emitting diode(LED) display, such as an organic LED (OLED) display.

The apparatus 500 may also include or be connected to a picture sensingdevice 520. The picture sensing device 520 is, for example, a camera orany other picture sensing device 520 that can sense a picture and thatis existing or to be developed in the future. The picture is, forexample, a picture of a user who runs the apparatus 500. The picturesensing device 520 may be placed directly facing a user who runs theapparatus 500. In an example, a position and an optical axis of thepicture sensing device 520 may be configured so that a field of view ofthe picture sensing device 520 includes a region closely adjacent to thedisplay 518 and the display 518 can be seen from the region.

The apparatus 500 may also include or be in communication with a soundsensing device 522, for example, a microphone or any other sound sensingdevice that is existing or to be developed in the future and that cansense sounds near the apparatus 500. The sound sensing device 522 may beplaced directly facing a user who runs the apparatus 500, and may beconfigured to receive a sound, for example, a voice or another sound,made by the user when running the apparatus 500.

Although FIG. 5 depicts the processor 502 and the memory 504 of theapparatus 500 as being integrated into a single unit, otherconfigurations may be utilized. Running of the processor 502 may bedistributed in a plurality of machines (each machine includes one ormore processors) that can be directly coupled, or distributed in a localregion or another network. The memory 504 can be distributed across aplurality of machines such as a network-based memory or a memory in aplurality of machines on which the apparatus 500 is run. Althoughdepicted herein as a single bus, the bus 512 of the apparatus 500 caninclude a plurality of buses. Further, the secondary storage 514 can bedirectly coupled to the other components of the apparatus 500 or can beaccessed over a network and can include a single integrated unit such asa memory card or a plurality of units such as a plurality of memorycards. The apparatus 500 can thus be implemented in a wide variety ofconfigurations.

As described above in this application, in addition to including a luma(Y) component, a color video further includes chroma components (U, V).Therefore, in addition to encoding on the luma component, the chromacomponents also need to be encoded. According to different methods forsampling the luma component and the chroma components in the colorvideo, there are usually YUV4:4:4, YUV4:2:2, and YUV4:2:0. As shown inFIG. 6, a cross represents a sample of a luma component, and a circlerepresents a sample of a chroma component.

-   -   A 4:4:4 format indicates that the chroma component is not        downsampled.    -   A 4:2:2 format indicates that, relative to the luma component,        2:1 horizontal downsampling is performed on a chroma component,        and no vertical downsampling is performed on the chroma        component. For every two U samples or V samples, each row        includes four Y samples.    -   A 4:2:0 format indicates that, relative to the luma component,        2:1 horizontal downsampling is performed on a chroma component,        and 2:1 vertical downsampling is performed on the chroma        component.

The video decoder may be configured to split a video block according tothree different split structures (QT, BT, and TT) by using fivedifferent split types allowed at each depth. The split types include aquadtree split (QT split structure), a horizontal binary tree split (BTsplit structure), a vertical binary tree split (BT split structure), anda horizontal center-side ternary tree split (TT split structure), and avertical center-side ternary tree split (TT split structure), as shownin FIG. 7A to FIG. 7E.

The five split types are defined as follows: It should be noted that asquare is considered as a special case of a rectangle.

Quadtree (QT) split: A block is further split into four rectangularblocks of a same size. FIG. 7A shows an example of a quadtree split.According to a CTU splitting method based on a quadtree QT, a CTU isused as a root node (root) of a quadtree. The CTU is recursively splitinto several leaf nodes (leaf node) based on a quadtree split mode. Onenode corresponds to one picture region. If a node is not split, the nodeis referred to as a leaf node, and a picture region corresponding to thenode becomes a CU. If a node is split, a picture region corresponding tothe node is split into four picture regions of a same size (the lengthand the width of the four regions are respectively half the length andthe width of the split region), and each region corresponds to one node.Whether these nodes are further split needs to be separately determined.Whether a node is to be split is indicated by a split flag split_cu_flagthat is in a bitstream and that corresponds to the node. A quadtreedepth (qtDepth) of the root node is 0, and a quadtree depth of a childnode is a quadtree depth of a parent node plus 1. For brevity ofdescription, a size and a shape of a node in this application are a sizeand a shape of a picture region corresponding to the node, that is, thenode is a rectangular region in a picture. A node obtained by splittinga node (node) in the coding tree may be referred to as a child node(child node) of the node, which is a child node for short.

More specifically, a 64×64 CTU node (with the quadtree depth of 0) maynot be split based on split_cu_flag corresponding to the CTU node, andbecome a 64×64 CU; or may be split into four 32×32 nodes (with thequadtree depth of 1). Each of the four 32×32 nodes may be further splitor not further split based on split_cu_flag corresponding to the node.If a 32×32 node continues to be split, four 16×16 nodes are generated(with the quadtree depth of 2). The rest may be deduced by analogy,until no node is further split. In this way, one CTU is split into onegroup of CUs. A minimum CU size (size) is specified in SPS. For example,8×8 is the minimum CU size. In the foregoing recursive partitioningprocess, if a size of a node is equal to the minimum CU size (minimum CUsize), the node is not to be further split by default, and a split flagof the node does not need to be included in a bitstream.

After it is learned, through parsing, that a node is a leaf node and theleaf node is a CU, coding information (including information such as aprediction mode and a transform coefficient of the CU, for example, asyntax structure coding_unit( ) in H.266) corresponding to the CU isfurther parsed. Then, decoding processing such as prediction,dequantization, inverse transform, and loop filtering is performed onthe CU based on the coding information, to generate a reconstructedimage corresponding to the CU. In a quadtree (QT) structure, the CTU canbe split into a group of CUs of appropriate sizes based on a localpicture feature. For example, a flat region is split into larger CUs,while a richly textured region is split into smaller CUs.

A mode of splitting a CTU into a group of CUs corresponds to a codingtree (coding tree). A specific coding tree that should be used by theCTU is usually determined by using a rate-distortion optimization (RDO)technology of an encoder. The encoder tries a plurality of CTU splitmodes, and each split mode corresponds to one rate distortion cost (RDcost). The encoder compares RD costs of the split modes that areattempted, to find a split mode with a minimum RD cost as an optimalsplit mode of the CTU, for actual coding of the CTU. The CTU split modestried by the encoder all need to comply with a split rule specified by adecoder, so that the CTU split modes can be correctly identified by thedecoder.

Vertical binary tree (BT) split: A block is vertically split into tworectangular blocks of a same size. FIG. 7B is an example of a verticalbinary tree split.

Horizontal binary tree split: A block is horizontally split into tworectangular blocks of a same size. FIG. 7C is an example of a horizontalbinary tree split.

Vertical center-side ternary tree (TT) split: A block is verticallysplit into three rectangular blocks, so that two side blocks are of asame size, and a size of a center block is a sum of the sizes of the twoside blocks. FIG. 7D is an example of a vertical center-side ternarytree split.

Horizontal center-side ternary tree split: A block is horizontally splitinto three rectangular blocks so that two side blocks are of a samesize, and a size of a center block is a sum of the sizes of the two sideblocks. FIG. 7E is an example of a horizontal center-side ternary treesplit.

Specific split methods in FIG. 7B to FIG. 7E are similar to descriptionsin FIG. 7A, and details are not described herein again. In addition, asplit mode of cascading a QT and a BT/TT may be used, which is QT-BTTfor short. That is, a node in a level-1 coding tree can be split intochild nodes only through QT, and a leaf node in the level-1 coding treeis a root node of a level-2 coding tree; a node in the level-2 codingtree may be split into child nodes by using one of the following foursplit modes: a horizontal binary split, a vertical binary split, ahorizontal ternary split, and a vertical ternary split; a leaf node ofthe level-2 coding tree is a coding unit. Specifically, a binary treesplit and a quadtree split are performed in a cascading manner, whichmay be a QTBT split mode for short. For example, a CTU is first splitthrough a QT, and a QT leaf node is allowed to continue to be splitthrough a BT, as shown in FIG. 8. In the right part of FIG. 8, eachendpoint represents one node. One node connecting to four solid linesrepresents a quadtree split, and one node connecting to two dashed linesrepresents a binary tree split. A node obtained after splitting may bereferred to as a child node of the node, which is a child node forshort. Among child nodes, a to m are 13 leaf nodes, and each leaf noderepresents one CU. On a binary tree node, 1 represents a vertical split,and 0 represents a horizontal split. A CTU is split into 13 CUs: a to m,as shown in the left part of FIG. 8. In the QTBT split mode, each CU hasa QT depth (Quad-tree depth, QT depth) and a BT depth (Binary treedepth, BT depth). The QT depth represents a QT depth of a QT leaf nodeto which the CU belongs, and the BT depth represents a BT depth of a BTleaf node to which the CU belongs. For example, in FIG. 8, QT depths ofa and b are 1, and BT depths of a and b are 2; QT depths of c, d, and eare 1, and BT depths of c, d, and e are 1; QT depths of f, k, and l are2, and BT depths of f, k, and l are 1; QT depths of i and j are 2, andBT depths of i and j are 0; QT depths of g and h are 2, and BT depths ofg and h are 2; a QT depth of m is 1, and a BT depth of m is 0. If a CTUis split into only one CU, a QT depth of the CU is 0, and a BT depth ofthe CU is 0.

For a block associated with a specific depth, the encoder 20 determineswhich split type (including no further split) is used, and explicitly orimplicitly (e.g., a split type may be derived from a predetermined rule)signals the determined split type to the decoder 30. The encoder 20 maydetermine a to-be-used split type based on a rate-distortion cost forchecking a different split type for a block.

If a 2×M chroma block, especially a 2×2, 2×4, or 2×8 chroma block, isgenerated by splitting a node, chroma encoding and decoding efficiencyis comparatively low, and processing costs of a hardware decoder iscomparatively high. This is unfavorable to implementation of thehardware decoder. When the chroma block of the current node is notfurther split, in this embodiment of this application, only a luma blockof the current node may be split, thereby improving encoding anddecoding efficiency, reducing a maximum throughput of a codec, andfacilitating implementation of the codec. Specifically, in thisembodiment of this application, when child nodes generated by splittinga node by using a split mode include a chroma block whose side length isa first threshold (or includes a chroma block whose side length is lessthan a second threshold), the luma block included in the node is splitby using this split mode, a chroma block included in the node is notfurther split. This mode can avoid generation of a chroma block whoseside length is the first threshold (or whose side length is less thanthe second threshold). In a specific implementation, the first thresholdmay be 2, and the second threshold may be 4. The following providesdetailed descriptions with reference to Embodiments 1 to 3. In thisembodiment of this application, descriptions are provided by using avideo data format of YUV4:2:0, and a similar manner may be used forYUV4:2:2 data.

An intra block copy (IBC) coding tool is adopted in an extended standardSCC of HEVC, and is mainly used to improve coding efficiency of a screencontent video. The IBC mode is a block-level coding mode. On an encoderside, a block matching (BM) method is used to find an optimal blockvector or motion vector for each CU. The motion vector herein is mainlyused to represent a displacement from the current block to a referenceblock, and is also referred to as a displacement vector. The referenceblock is a reconstructed block in the current picture. The IBC mode maybe considered as a third prediction mode other than the intra predictionmode or the inter prediction mode. To save storage space and reducecomplexity of the decoder, the IBC mode in VTM4 allows only areconstructed part of a predefined region of the current CTU to be usedfor prediction.

In VTM, at a CU level, a flag is used to indicate whether an IBC mode isused for a current CU. The IBC mode is classified into an IBC AMVP mode,an IBC skip mode, or an IBC merge mode.

Embodiment 1

FIG. 9 is a flowchart of a method 900 according to Embodiment 1 of thepresent invention.

Step 901: Determine whether a current node needs to be split, where thecurrent node includes a luma block and a chroma block.

If the current node is not further split into child nodes, the currentnode is a coding unit (CU), and step 910 is performed to obtaininformation about the coding unit through parsing; or if the currentnode needs to be split, step 902 is performed.

Embodiment 1 of the present invention may be implemented by a videodecoding apparatus, to be specific, the apparatus described in any oneof FIG. 3 to FIG. 5.

Embodiment 1 of the present invention may alternatively be implementedby a video encoding apparatus, to be specific, the apparatus describedin any one of FIG. 2, FIG. 4, and FIG. 5.

When Embodiment 1 is implemented by the video decoding apparatus, step902 is: The video decoding apparatus parses a bitstream to determine asplit mode of the current node. The split mode of the current node maybe at least one of a quad split (QT), a horizontal binary split(horizontal BT), a horizontal ternary split (horizontal TT), a verticalbinary split (Vertical BT), and a vertical ternary split (Vertical TT),or may be another split mode. This is not limited in this illustrativeexample of the present invention. Information about the split mode ofthe current node is usually transmitted in the bitstream, and the splitmode of the current node can be obtained by parsing a correspondingsyntax element in the bitstream.

When Embodiment 1 is implemented by the video encoding apparatus, step902 is: Determine a method for splitting the current node.

Step 904: Determine, based on the split mode of the current node and asize of the current node, whether the chroma block of the current nodeneeds to be split; and when the chroma block of the current node is notfurther split, perform step 906; or when the chroma block of the currentnode needs to be split, perform step 908.

Specifically, in an implementation, it may be determined whether achroma block whose side length is a first threshold (or a chroma blockwhose side length is less than a second threshold) is generated bysplitting the current node based on the split mode of the current node.If it is determined that a child node generated by splitting the currentnode includes the chroma block whose side length is the first threshold(or include the chroma block whose side length is less than the secondthreshold), the chroma block of the current node is not further split.For example, the first threshold may be 2, and the second threshold maybe 4.

In this illustrative example of the present invention, the chroma blockwhose side length is the first threshold is a chroma block whose widthor height is the first threshold.

In another implementation, for example, when any one of condition 1 tocondition 5 is true, it may be determined that the chroma block of thecurrent node is not further split; otherwise, it is determined that thechroma block of the current node needs to be split:

condition 1: The width of the current node is equal to twice a secondthreshold, and the split mode of the current node is a vertical binarysplit;

condition 2: The height of the current node is equal to twice a secondthreshold, and the split mode of the current node is a horizontal binarysplit;

condition 3: The width of the current node is equal to four times asecond threshold, and the split mode of the current node is a verticalternary split;

condition 4: The height of the current node is equal to four times asecond threshold, and the split mode of the current node is a horizontalternary split; or

condition 5: The width of the current node is equal to twice a secondthreshold, and the split mode of the current node is a quad split.

Generally, the width of the current node is the width of the luma blockcorresponding to the current node, and the height of the current node isthe height of the luma block corresponding to the current node. In aspecific implementation, for example, the second threshold may be 4.

In a third implementation, it may be determined whether a chroma blockwhose width is a first threshold (or a chroma block whose width is lessthan a second threshold) is generated by splitting the current nodebased on the split mode of the current node. If it is determined that achild node generated by splitting the current node includes the chromablock whose width is the first threshold (or include the chroma blockwhose width is less than the second threshold), the chroma block of thecurrent node is not further split. For example, the first threshold maybe 2, and the second threshold may be 4.

In a fourth implementation, it may be determined whether a chroma blockwhose chroma sample quantity is less than a third threshold is generatedby splitting the current node based on the split mode of the currentnode. If it is determined that a child node generated by splitting thecurrent node includes a chroma block whose chroma sample quantity isless than the third threshold, the chroma block of the current node isnot further split. For example, the third threshold may be 16. In thiscase, a chroma block whose chroma sample quantity is less than 16includes but is not limited to a 2×2 chroma block, a 2×4 chroma block,and a 4×2 chroma block. The third threshold may be 8. In this case, achroma block whose chroma sample quantity is less than 8 includes but isnot limited to a 2×2 chroma block.

Specifically, if either condition 1 or condition 2 is true, it may bedetermined that the chroma block whose chroma sample quantity is lessthan the third threshold is generated by splitting the current nodebased on the split mode of the current node; otherwise, it may bedetermined that no chroma block whose chroma sample quantity is lessthan the third threshold is generated by splitting the current nodebased on the split mode of the current node:

condition 1: A product of the width and the height of the current nodeis less than 128, and the split mode of the current node is a verticalbinary split or a horizontal binary split; or

condition 2: A product of the width and the height of the current nodeis less than 256, and the split mode of the current node is a verticalternary split, a horizontal ternary split, or a quad split.

Specifically, in another implementation, if either condition 3 orcondition 4 is true, it may be determined that the chroma block whosechroma sample quantity is less than a third threshold is generated bysplitting the current node based on the split mode of the current node;otherwise, it may be determined that no chroma block whose chroma samplequantity is less than the third threshold is generated by splitting thecurrent node based on the split mode of the current node:

condition 3: A product of the width and the height of the current nodeis equal to 64, and the split mode of the current node is a verticalbinary split, a horizontal binary split, a quad split, a horizontalternary split, or a vertical ternary split; or

condition 4: A product of the width and the height of the current nodeis equal to 128, and the split mode of the current node is a verticalternary split or a horizontal ternary split.

In a fifth implementation, it may be determined whether a chroma blockwhose height is a first threshold (or a chroma block whose height isless than a second threshold) is generated by splitting the current nodebased on the split mode of the current node. If it is determined that achild node generated by splitting the current node includes a chromablock whose height is the first threshold (or a chroma block whoseheight is less than the second threshold), the chroma block of thecurrent node is not further split. For example, the first threshold maybe 2, and the second threshold may be 4.

Step 906: Split the luma block of the current node based on the splitmode of the current node, to obtain the child nodes (which may also bereferred to as child nodes of the luma block, luma nodes for short) ofthe current node. Each child node includes only a luma block. The chromablock of the current node is not further split, and becomes a codingunit including only the chroma block.

Optionally, as shown in FIG. 10, step 906 may further include step 9062:Parse the luma block of the current node, to obtain predictioninformation and residual information of each of sub-regions in the lumablock of the current node, where each sub-region corresponds to onechild node.

Specifically, step 9062 may be implemented by using any one of thefollowing methods:

Method 1: Do not further split each child node of the luma block bydefault (that is, each luma node is a coding unit, and one child node ofthe luma block corresponds to one coding unit including only a lumablock), and sequentially parse coding unit data for the child nodes ofthe luma block, to obtain prediction information and residualinformation of each luma block. A luma block of a luma node is asub-region in the luma block of the current node, and luma blocks of theluma nodes constitute the luma block of the current node.

Method 2: Determine whether the child nodes of the luma block need tocontinue to be further split sequentially; and when the child nodes needto be further split, parse a split mode of the child nodes andcorresponding coding unit data. More specifically, if a luma node is notfurther split, coding unit data corresponding to the luma node isparsed, to obtain prediction information and residual information thatcorrespond to a luma block of the luma node; or if a luma node continuesto be split, whether child nodes (it should be noted that the child nodestill includes only a luma block) of the luma node need to be splitcontinues to be determined, until prediction information and residualinformation of each of sub-regions of the luma block of the current nodeare determined.

The prediction information includes but is not limited to a predictionmode (indicating an intra prediction mode or an inter prediction mode),an intra prediction mode, motion information, and/or the like. The intraprediction mode of the luma block may be one of a planar mode, a directcurrent mode (DC Mode), an angular mode, and a chroma derived mode (DM).The motion information may include information such as a predictiondirection (forward, backward, or bidirectional), a reference index,and/or a motion vector.

The residual information includes a coded block flag (CBF), a transformcoefficient, and/or a transform type (e.g., DCT-2, DST-7, or DCT-8), andthe like.

Optionally, as shown in FIG. 10, step 906 may further include step 9064:Obtain prediction information and/or residual information of the chromablock.

Specifically, step 9064 may include step 90642 and step 90644. Step90642 may be step 90642A or step 90642B.

Step 90642A specifically includes:

Obtain a prediction mode for a preset position of the luma block of thecurrent node as the prediction mode of the chroma block of the currentnode. A position of the top-left corner of the luma block of the currentnode may be expressed as (x0, y0), and a size is W×H. In this case, thepreset position may include but is not limited to the top-left corner,the bottom-right corner (x0+W−1, y0+H−1), the center (x0+W/2, y0+H/2),(x0+W/2, 0), or (0, y0+H/2) of the luma block, or the like. Theprediction mode indicates whether intra prediction or inter predictionis performed on a pixel in the preset position, for example, informationindicated by a syntax element pred_mode_flag in HEVC. For example, inVTM, whether the prediction mode for the preset position is an IBC modemay be determined based on information indicated by a syntax elementpred_mode_ibc_flag.

If the prediction mode for the preset position is inter prediction, oneof the following methods is used to determine the prediction mode of thechroma block:

Method 1: Perform inter prediction on the chroma block to obtain motioninformation for the preset position as motion information of the chromablock.

Method 2: Perform inter prediction on the chroma block, and split thechroma block into chroma prediction sub-blocks (where a size of thechroma prediction sub-block is, for example, two chroma samples in widthand two chroma samples in height), and obtain motion information of thechroma prediction sub-blocks in the following manner:

If inter prediction is performed on luma blocks in luma picturepositions corresponding to the chroma prediction sub-blocks, motioninformation of the luma picture positions corresponding to the chromaprediction sub-blocks is used as the motion information of the chromaprediction sub-blocks; otherwise, motion information for the presetposition is obtained as the motion information of the chroma predictionsub-blocks.

For a YUV4:2:0 picture, coordinates of a chroma prediction sub-block ina chroma picture are denoted as (xC, yC). In this case, coordinates of aluma picture position corresponding to the chroma prediction sub-blockare (xC<<1, yC<<1).

Method 3: Parse a flag pred_mode_flag, to determine whether intraprediction or inter prediction is performed on the chroma block; and ifintra prediction is performed on the chroma block, parse an intraprediction mode from a bitstream as an intra prediction mode of thechroma block; or if inter prediction is performed on the chroma block,obtain motion information for a preset position as the motioninformation of the chroma block.

Method 4: Parse a flag pred_mode_flag, to determine whether intraprediction or inter prediction is performed on the chroma block; and ifintra prediction is performed on the chroma block, parse an intraprediction mode from a bitstream as an intra prediction mode of thechroma block, where the intra prediction mode may be one of across-component linear model mode and a DM mode, and a luma intraprediction mode corresponding to the DM mode is set to a planar mode; orif inter prediction is performed on the chroma block, split the chromablock into chroma prediction sub-blocks, where motion information of thechroma prediction sub-blocks is obtained in the following manner:

If inter prediction is performed on luma blocks in luma picturepositions corresponding to the chroma prediction sub-blocks, motioninformation of the luma picture positions corresponding to the chromaprediction sub-blocks is used as the motion information of the chromaprediction sub-blocks; otherwise, motion information for the presetposition is obtained as the motion information of the chroma predictionsub-blocks.

A context model used to parse the flag pred_mode_flag is a preset model,for example, with a model number 2.

If the prediction mode for the preset position is intra prediction,intra prediction is performed on the chroma block, and an intraprediction mode is parsed from the bitstream as the intra predictionmode of the chroma block. Alternatively, it is directly determined thatthe intra prediction mode of the chroma block is one of a direct currentmode, a planar mode, an angular mode, a cross-component linear modelmode, or a DM mode.

If the prediction mode for the preset position is an IBC mode, thechroma block is predicted in the IBC mode, to obtain displacement vectorinformation for the preset position as displacement vector informationof the chroma block; or

if the prediction mode for the preset position is an IBC mode, theprediction mode of the chroma block is determined based on the flagpred_mode_ibc_flag: 1) if pred_mode_ibc_flag is 1, the IBC mode is usedfor the chroma block; more specifically, a method for predicting the IBCfor the chroma block may be a method in VTM 4.0, that is, the chromablock is split into 2×2 sub-blocks, and a displacement vector of eachsub-block is equal to a displacement vector of a luma regioncorresponding to the sub-block; or 2) if pred_mode_ibc_flag is 0, anintra prediction mode or an inter prediction mode is used for the chromablock.

When the intra prediction mode is used, a syntax element is parsed fromthe bitstream, to determine a chroma intra prediction mode.Alternatively, it is directly determined that the intra prediction modeof the chroma block belongs to a chroma intra prediction mode set. Thechroma intra prediction mode set include a direct current mode, a planarmode, an angular mode, a cross-component linear model, and a DM mode.

When the inter prediction mode is used, motion information for thepreset position may be obtained as the motion information of the chromablock.

It should be noted that, when there is no pred_mode_ibc_flag in thebitstream, if a type of a picture in which the current node is locatedis an I-frame/I-slice and an IBC mode is allowed for use,pred_mode_ibc_flag is 1 by default, that is, the IBC mode is used forthe chroma block by default; or if a type of a picture in which thecurrent node is located is a P/B-frame/slice, pred_mode_ibc_flag is 0 bydefault.

In VTM, whether the prediction mode for the preset position is an IBCmode may be determined based on information indicated by the syntaxelement pred_mode_ibc_flag. For example, if pred_mode_ibc_flag is 1, itindicates that the IBC prediction mode is used; or if pred_mode_ibc_flagis 0, it indicates that the IBC mode is not used. When there is nopred_mode_ibc_flag in the bitstream, if in the I-frame/I-slice, a valueof pred_mode_ibc_flag is equal to a value of sps_ibc_enabled_flag; if inthe P-frame/slice or the B-frame/slice, pred_mode_ibc_flag is 0. Whensps_ibc_enabled_flag is 1, it indicates that the current picture isallowed to be used as a reference picture in a process of decoding thecurrent picture; or when sps_ibc_enabled_flag is 0, it indicates thatthe current picture is not allowed to be used as a reference picture ina process of decoding the current picture.

The intra prediction mode of the chroma block may be one of a directcurrent mode, a planar mode, an angular mode, a cross-component linearmodel (CCLM) mode, and a chroma derived mode (DM), for example, a DCmode, a planar mode, an angular mode, a cross-component linear modelmode, and a chroma derived mode in VTM.

Step 90642B specifically includes:

Obtain prediction modes for a plurality of luma blocks of the currentnode, and determine the prediction mode of the chroma blockcorresponding to the current node by using the following method:

If intra prediction is performed on all of the plurality of luma blocks,intra prediction is performed on the chroma block, and an intraprediction mode is parsed from a bitstream as the intra prediction modeof the chroma block.

If inter prediction is performed on all of the plurality of luma blocks,one of the following methods is used to determine a chroma predictionmode:

Method 1: Perform inter prediction on the chroma block to obtain motioninformation for the preset position as motion information of the chromablock. The preset position has the same meaning as that in Embodiment 1.

Method 2: Parse the flag pred_mode_flag to determine whether intraprediction or inter prediction is performed on the chroma block; and ifintra prediction is performed on the chroma block, parse an intraprediction mode from the bitstream as the intra prediction mode of thechroma block; or if inter prediction is performed on the chroma block,obtain motion information for the preset position as the motioninformation of the chroma block.

If inter prediction and intra prediction are included for the pluralityof luma blocks, the mode information of the chroma block may bedetermined in one of the following manners:

(1) if the prediction mode for the preset position is inter prediction,inter prediction is performed on the chroma block to obtain motioninformation for the preset position as the motion information of thechroma block;

(2) if the prediction mode for the preset position is intra prediction,intra prediction is performed on the chroma block, and an intraprediction mode is parsed from a bitstream as the intra prediction modeof the chroma block; or it is directly determined that the intraprediction mode of the chroma block is one of a direct current mode, aplanar mode, an angular mode, a cross-component linear model mode, or aDM mode;

(3) if the prediction mode for the preset position is an IBC mode, thechroma block is predicted in the IBC mode, to obtain displacement vectorinformation for the preset position as displacement vector informationof the chroma block; and

(4) the chroma prediction mode is directly specified as one mode in amode set, where the mode set includes an AMVP mode, an IBC mode, a skipmode, a direct current mode, a planar mode, an angular mode, across-component linear model mode, and a DM mode.

Step 90644: Parse residual information of the chroma block. A residualinformation of the chroma block is included in a transform unit. Atransform type may be DCT-2 by default.

Step 908: Split the current node into child nodes, where each child nodeincludes a luma block and a chroma block. Step 901 is performed on eachchild node, and parsing continues to be performed for a split mode ofthe child node, to determine whether the child node (which is alsoreferred to as a node) needs to be further split.

After a sub-region split mode of a luma block and prediction informationand residual information of each of sub-regions are obtained, interprediction processing or intra prediction processing may be performed oneach sub-region based on a corresponding prediction mode of thesub-region, to obtain an inter predicted picture or an intra predictedpicture of the sub-region. Then, dequantization and inverse transformprocessing are performed on a transform coefficient based on theresidual information of each of sub-regions to obtain a residualpicture, and the residual picture is superimposed on a predicted picturein the corresponding sub-region, to generate a reconstructed picture ofthe luma block.

After prediction information and residual information of a chroma blockare obtained, inter prediction processing or intra prediction processingmay be performed on the chroma block based on a prediction mode of thechroma block, to obtain an inter predicted picture or an intra predictedpicture of the chroma block. Then, dequantization and inverse transformprocessing are performed on a transform coefficient based on theresidual information of the chroma block to obtain a residual picture,and the residual picture is superimposed on a predicted picture of thechroma block to generate a reconstructed picture of the chroma block.

In Embodiment 1 of the present invention, when the chroma block of thecurrent node is not further split, the method may be used to split onlythe luma block of the current node, thereby improving encoding anddecoding efficiency, reducing a maximum throughput of a codec, andfacilitating implementation of the codec.

Embodiment 2

Compared with Embodiment 1, the following constraint is added to step9062: A same prediction mode is used for the luma nodes (that is, thechild nodes of the luma blocks), that is, intra prediction or interprediction is performed on each luma node. Other steps are similar tothose in Embodiment 1, and details are not described again.

Any one of the following methods may be used for using the sameprediction mode for the luma nodes:

Method 1: If the current frame is an I-frame, intra prediction isperformed on all child nodes of the current node by default; or if thecurrent frame is a P-frame or a B-frame, a first node (which may be afirst child node for short) on which parsing processing is performed isparsed to obtain a prediction mode of the first node, and a predictionmode of a remaining child node (which is a luma node for short) is bydefault the prediction mode of the first node on which parsingprocessing is performed; or

method 2: If the current frame is an I-frame, intra prediction isperformed on all child nodes of the current node by default; or if thecurrent frame is a P-frame or a B-frame, inter prediction is performedon all child nodes of the current node by default.

Embodiment 3

FIG. 11 is a flowchart 1100 of a method according to Embodiment 3 of thepresent invention. Embodiment 3 is similar to Embodiment 1, except step1104.

Step 1104: Determine, based on a split mode of the current node, a sizeof the current node, and a prediction mode of the first node on whichparsing processing is performed (which may be the first child node forshort) in the current node, whether the chroma block of the current nodeis split, where the first child node includes only a luma block. A sameprediction mode is performed on a plurality of child nodes of thecurrent node. Each child node includes only a luma block.

Whether the split mode of the current node and the size of the currentnode are first determined or the prediction mode of the first child nodeis first determined is not limited in this illustrative example of thepresent invention.

Based on Embodiment 1 or 2, in Embodiment 3, a split mode of the chromablock of the current node, a corresponding prediction informationparsing mode, and a corresponding residual information parsing mode aredetermined with reference to the prediction mode of the first child nodeof the current node.

In an implementation, it is determined, based on the split mode of thecurrent node and the size of the current node, that a child nodegenerated by splitting the current node includes a chroma block whoseside length is equal to a first threshold or whose side length is lessthan a second threshold, and a prediction mode of the first child nodeis intra prediction; in this case, the chroma block of the current nodeis not further split. Similar to Embodiment 1, for example, the firstthreshold may be 2, and the second threshold may be 4.

In this illustrative example of the present invention, the chroma blockwhose side length is the first threshold is a chroma block whose widthor height is the first threshold.

In another implementation, when the prediction mode of the first childnode is intra prediction, and any one of condition 1 to condition 5 istrue:

condition 1: The width of the current node is equal to twice a secondthreshold, and the split mode of the current node is a vertical binarysplit;

condition 2: The height of the current node is equal to twice a secondthreshold, and the split mode of the current node is a horizontal binarysplit;

condition 3: The width of the current node is equal to four times asecond threshold, and the split mode of the current node is a verticalternary split;

condition 4: The height of the current node is equal to four times asecond threshold, and the split mode of the current node is a horizontalternary split; or

condition 5: If the width of the current node is equal to twice a secondthreshold and the split mode of the current node is a quad split, thechroma block of the current node is not further split.

Generally, the width of the current node is the width of the luma blockcorresponding to the current node, and the height of the current node isthe height of the luma block corresponding to the current node. In aspecific implementation, for example, the second threshold may be 4.

When the prediction mode of the first child node is intra prediction,similar to the first embodiment, in a third implementation, it may bedetermined whether a chroma block whose width is the first threshold (ora chroma block whose width is less than the second threshold) isgenerated by splitting the current node based on the split mode of thecurrent node. If it is determined that a child node generated bysplitting the current node includes a chroma block whose width is thefirst threshold (or a chroma block whose width is less than the secondthreshold), and the prediction mode of the first child node is intraprediction, the chroma block of the current node is not further split.For example, the first threshold may be 2, and the second threshold maybe 4.

When the prediction mode of the first child node is intra prediction,similar to the first embodiment, in a fourth implementation, it may bedetermined whether a chroma block whose chroma sample quantity is lessthan a third threshold is generated by splitting the current node basedon the split mode of the current node. If it is determined that a childnode generated by splitting the current node includes a chroma blockwhose chroma sample quantity is less than the third threshold, and theprediction mode of the first child node is intra prediction, the chromablock of the current node is not further split. For example, the thirdthreshold may be 16. In this case, a chroma block whose chroma samplequantity is less than 16 includes but is not limited to a 2×2 chromablock, a 2×4 chroma block, and a 4×2 chroma block. The third thresholdmay be 8. In this case, a chroma block whose chroma sample quantity isless than 8 includes but is not limited to a 2×2 chroma block.

Specifically, if either condition 1 or condition 2 is true, it may bedetermined that the chroma block whose chroma sample quantity is lessthan the third threshold is generated by splitting the current nodebased on the split mode of the current node; otherwise, it may bedetermined that no chroma block whose chroma sample quantity is lessthan the third threshold is generated by splitting the current nodebased on the split mode of the current node:

condition 1: A product of the width and the height of the current nodeis less than 128, and the split mode of the current node is a verticalbinary split or a horizontal binary split; or

condition 2: A product of the width and the height of the current nodeis less than 256, and the split mode of the current node is a verticalternary split, a horizontal ternary split, or a quad split.

Specifically, in another implementation, if either condition 3 orcondition 4 is true, it may be determined that the chroma block whosechroma sample quantity is less than a third threshold is generated bysplitting the current node based on the split mode of the current node;otherwise, it may be determined that no chroma block whose chroma samplequantity is less than the third threshold is generated by splitting thecurrent node based on the split mode of the current node:

condition 3: A product of the width and the height of the current nodeis equal to 64, and the split mode of the current node is a verticalbinary split, a horizontal binary split, a quad split, a horizontalternary split, or a vertical ternary split; or

condition 4: A product of the width and the height of the current nodeis equal to 128, and the split mode of the current node is a verticalternary split or a horizontal ternary split.

When the prediction mode of the first child node is intra prediction,similar to the first embodiment, in a fifth implementation, it may bedetermined whether a chroma block whose height is a first threshold (ora chroma block whose height is less than a second threshold) isgenerated by splitting the current node based on the split mode of thecurrent node. If it is determined that a child node generated bysplitting the current node includes a chroma block whose height is thefirst threshold (or a chroma block whose height is less than the secondthreshold), and the prediction mode of the first child node is intraprediction, the chroma block of the current node is not further split.For example, the first threshold may be 2, and the second threshold maybe 4.

If the chroma block of the current node is not further split, the chromablock of the current node becomes a coding unit including only a chromablock. The method 1100 may further include: obtaining predictioninformation and/or residual information of the chroma block.

In another implementation, it is determined, based on the split mode ofthe current node and the size of the current node, that a child nodegenerated by splitting the current node includes a chroma block whoseside length is less than a threshold. If the prediction mode of thefirst child node is inter prediction, the chroma block of the currentnode is split based on the split mode of the current node. Optionally,motion information of a corresponding child node of the chroma block isdetermined based on motion information of a child node of the currentnode. For example, motion information of a child node of the chromablock of the current node may be set as motion information of acorresponding luma node (that is, motion information of each child nodeof the chroma block does not need to be parsed from the bitstream).Child nodes of the chroma block are parsed to obtain residualinformation of the child nodes of the chroma block.

When the prediction mode of the first child node is inter prediction,and any one of the following conditions is true:

condition 1: The width of the current node is equal to twice a secondthreshold, and the split mode of the current node is a vertical binarysplit;

condition 2: The height of the current node is equal to twice a secondthreshold, and the split mode of the current node is a horizontal binarysplit;

condition 3: The width of the current node is equal to four times asecond threshold, and the split mode of the current node is a verticalternary split;

condition 4: The height of the current node is equal to four times asecond threshold, and the split mode of the current node is a horizontalternary split; or

condition 5: If the width of the current node is equal to twice thesecond threshold and the split mode of the current node is a quad split,the chroma block of the current node still needs to be split.

Generally, the width of the current node is the width of the luma blockcorresponding to the current node, and the height of the current node isthe height of the luma block corresponding to the current node. In aspecific implementation, for example, the second threshold may be 4.

In Embodiment 3, a chroma block split mode, a corresponding predictioninformation parsing mode, and a corresponding residual informationparsing mode may also be determined based on a prediction mode of a lumanode. In this way, higher flexibility is achieved. In addition, when anprediction mode of the luma node is intra prediction, the chroma blockof the current node is not further split, thereby improving chromaencoding and decoding efficiency, reducing a maximum throughput of acodec and facilitating implementation of the codec.

Some syntax structures at a CU level may be shown in Table 1. If thecurrent node is not further split into child nodes, the current node isa coding unit, and a prediction block of the coding unit is parsedaccording to the following syntax structures.

skip_flag is a flag representing a skip mode. When a value of skip_flagis 1, it indicates that a skip mode is used for the current CU; or whena value of skip_flag is 0, it indicates that no skip mode is used forthe current CU.

merge_flag is a flag representing a direct mode. When a value ofmerge_flag is 1, it indicates that a merge mode is used for the currentCU; or when a value of merge_flag is 0, it indicates that no merge modeis used.

cu_pred_mode is a flag representing a prediction mode of a coding unit.When a value of cu_pred_mode is 1, it indicates that an intra predictionmode is used for the current coding unit; or when a value ofcu_pred_mode is 0, it indicates that a common inter prediction mode isused for the current coding unit.

TABLE 1 coding_unit( x0, y0, uiDepth, uiWidth, uiHeight ) {  ... skip_flag  ...  if ( ! skipFlag ) {    merge_flag    ...   }  if ( !mergeFlag )    cu_pred_mode    ... }

Some syntax parsing at a CU level may be shown in Table 2. Table 2 ismerely an example. In Table 2, a meaning of skip_flag is the same asthat of skip_flag in Table 1, and a meaning of pred_mode_flag is thesame as that of cu_pred_mode in Table 1.

cu_skip_flag is a flag representing a skip mode. When a value ofcu_skip_flag is 1, it indicates that a skip mode is used for the currentCU; or when a value of cu_skip_flag is 0, it indicates that no skip modeis used for the current CU.

merge_flag is a flag representing a direct mode. When a value ofmerge_flag is 1, it indicates that a merge mode is used for the currentCU; or when a value of merge_flag is 0, it indicates that no merge modeis used.

pred_mode_flag is a flag representing a prediction mode of a codingunit. When a value of pred_mode_flag is 1, it indicates that an intraprediction mode is used for a current prediction unit; or when a valueof pred_mode_flag is 0, it indicates that a common inter prediction modeis used for a current prediction unit. If the value of pred_mode_flag is1, a value of CuPredMode[x0][y0] is MODE_INTRA; or if the value ofpred_mode_flag is 0, a value of CuPredMode[x0][y0] is MODE_INTER.

TABLE 2 Descriptor coding_unit(x0, y0, cbWidth, cbHeight, treeType) { if(tile_group_type != I | | sps_ibc_enabled_flag) {   if(treeType !=DUAL_TREE_CHROMA)    cu_skip_flag[x0][y0] ae(v)  if(cu_skip_flag[x0][y0] = = 0 && tile_group_type   != I)   pred_mode_flag ae(v)   ...  }  if(CuPredMode[x0][y0] = = MODE_INTRA ){  ...  } else if(treeType != DUAL_TREE_CHROMA) {/* MODE_INTER orMODE_IBC */   if(cu_skip_flag[x0][y0] = = 0)    merge_flag[x0][y0] ae(v)  ...  } }

A node with a size of 8×M (or M×8) is split into two child nodes with asize of 4×M (or M×4) in a vertical binary split (or horizontal binarysplit) mode. Similarly, a node with a size of 16×M (or M×16) is splitinto four child nodes with a size of 4×M (or M×4) and one child nodewith a size of 8×N (or N×8) in a vertically extended quad split (orhorizontally extended quad split) mode. Similarly, a node with a size of16×M (or M×16) is split in a vertical ternary split (or horizontalternary split) mode to generate child nodes with a size of two 4×M (orM×4) and one child node with a size of 8×M (or M×8). For a data formatof YUV4:2:0, a resolution of a chroma component is ½ of a lumacomponent. That is, a 4×M node includes one 4×M luma block and two2×(M/2) chroma blocks. For a hardware decoder, processing costs of smallblocks (especially with a size of 2×2, 2×4, and 2×8) are comparativelyhigh. However, in this split mode, small blocks with a size of 2×2, 2×4,and the like are generated, which is unfavorable to implementation ofthe hardware decoder. For the hardware decoder, processing complexity ofthe small blocks is comparatively high, which is specifically embodiedin the following three aspects.

(1) Problems in intra prediction: In hardware design, to improve aprocessing speed, 16 pixels are usually simultaneously processed oncefor intra prediction, and a small block with a size of 2×2, 2×4, 4×2, orthe like includes less than 16 pixels, reducing intra predictionprocessing performance.

(2) Problems in coefficient coding: In HEVC, transform coefficientcoding is based on a coefficient group (CG) including 16 coefficients,but a small block with a size of 2×2, 2×4, 4×2, or the like includesfour or eight transform coefficients. As a result, coefficient groupsincluding four coefficients and eight coefficients need to be added tosupport coefficient encoding of these small blocks; consequently,implementation complexity is increased.

(3) Problems in inter prediction: inter prediction on a small blockraises a comparatively high requirement on a data bandwidth, and alsoaffects a decoding processing speed.

When a node is further split based on a split mode, and one of generatedchild nodes includes a chroma block whose side length is 2, a luma blockincluded in the child node continues to be further split in this splitmode, and a chroma block included in the child node is not furthersplit. This mode can avoid generation of a chroma block whose sidelength is 2, reduce a maximum throughput of a decoder, and facilitateimplementation of the decoder. In addition, a method for determining achroma block prediction mode based on a luma block prediction mode isproposed, effectively improving coding efficiency.

The method provided in the illustrative example of the present inventionmay be applied to the video codec in the foregoing embodiment.

Embodiment 4

This embodiment relates to a block split mode in video decoding. A videodata format in this embodiment is a YUV4:2:0 format. A similar mode maybe used for YUV4:2:2 data.

Step 1: Parse a split mode S of a node A, where if the node A continuesto be split, step 2 is performed; or if the current node is not furthersplit into child nodes, the current node corresponds to one coding unit,and information about a coding unit is obtained through parsing.

The split mode of the node A may be at least one of a quadtree split, avertical binary split, a horizontal binary split, a vertical ternarysplit, and a horizontal ternary split, or may be another split mode. Thesplit mode of the node A is not limited in the illustrative example ofthe present invention. Split mode information of the current node may betransmitted in a bitstream, and the split mode of the current node maybe obtained by parsing a corresponding syntax element in the bitstream.The split mode of the current node may alternatively be determinedaccording to a preset rule, and is not limited in the illustrativeexample of the present invention.

Step 2: Determine whether a chroma block of at least one child node B inchild nodes obtained by splitting the node A based on the split mode Sis a small block (or whether the width, the height, and/or the splitmode of the node A, and/or the width and the height of the node B meetat least one of the conditions). If a chroma block of at least one childnode B in the child nodes obtained by splitting the node A is a smallblock, step 3 to step 6 are performed.

Specifically, one of the following methods may be used to determinewhether a chroma block of at least one child node B of the node A is asub-block:

(1) If a chroma block of at least one child node B of the node A has asize of 2×2, 2×4, or 4×2, the chroma block of the at least one childnode B of the node A is a small block;

(2) if the width or height of a chroma block of at least one child nodeB of the node A is 2, the chroma block of the at least one child node Bof the node A is a small block;

(3) if the node A includes 128 luma samples and a ternary tree split isperformed on the node A, or the node A includes 64 luma samples and abinary tree split is performed on the node A, a quadtree split mode, ora ternary tree split mode, a chroma block of at least one child node Bof the node A is a small block;

(4) if the node A includes 256 luma samples and the node is split in aternary tree split mode or a quadtree split mode, or the node A includes128 luma samples and the node is split in a binary tree split mode, achroma block of at least one child node B of the node A is a smallblock;

(5) if the node A includes N1 luma samples and a ternary tree split isperformed on the node A, where N1 is 64, 128, or 256;

(6) if the node A includes N2 luma samples and a quadtree split isperformed on the node A, where N2 is 64 or 256; or

(7) if the node A includes N3 luma samples and the node A is split in abinary tree split mode, where N3 is 64, 128, or 256.

It should be noted that, that the node A includes 128 luma samples mayalso be described as that an area of the current node is 128, or aproduct of the width and the height of the node A is 128. Details arenot described herein.

Step 3: Restrict that intra prediction or inter prediction is performedon all coding units in a coverage area of the node A. For intraprediction and inter prediction on all the coding units, parallelprocessing on small blocks may be implemented by hardware, therebyimproving encoding and decoding performance.

One of the following methods may be used to determine to perform intraprediction or inter prediction on all the coding units in the coveragearea of the node A.

Method 1: Determining is performed based on a flag in a syntax table.

If a chroma block of at least one child node B obtained by splitting thenode A based on the split mode S is a small block (and a chroma block ofthe node A is not a small block), a flag cons_pred_mode_flag is parsedfrom the bitstream. When a value of cons_pred_mode_flag is 0, itindicates that inter prediction is performed on all the coding units inthe coverage area of the node A; or when a value of cons_pred_mode_flagis 1, it indicates that intra prediction is performed on all the codingunits in the coverage area of the node A. cons_pred_mode_flag may be asyntax element that needs to be parsed in a block split process. Whenthe syntax element is parsed, cu_pred_mode of the coding unit in thecoverage area of the node A may be no longer parsed, and a value ofcu_pred_mode is a default value corresponding to the value ofcons_pred_mode_flag.

It should be noted that, if only an intra prediction mode can be usedfor the child nodes of the node A, for example, the node A is in anintra picture (that is, a type of a picture in which the node A islocated is an intra type or an I-type), or the node A is in an intrapicture and an IBC technology is not used for a sequence, a value ofcons_pred_mode_flag is 1 by default, and cons_pred_mode_flag is notpresent in the bitstream. The IBC technology may belong to interprediction, or may belong to intra prediction.

Method 2: Determining is performed based on a prediction mode of thefirst node in the region of the node A.

A prediction mode of the first coding unit B0 (where the prediction modeof the first coding unit B0 is not limited) in the region of the node Ais parsed. If the prediction mode of the B0 is intra prediction, intraprediction is performed on all the coding units in the coverage area ofthe node A; or if the prediction mode of the B0 is inter prediction,inter prediction is performed on all the coding units in the coveragearea of the node A.

Step 4: Determine a chroma block split mode and a luma block split modeof the node A based on a prediction mode used for the coding units inthe coverage area of the node A.

If an intra prediction mode is used for all the coding units in thecoverage area of the node A, a luma block of the node A is split basedon the split mode S, to obtain N luma coding tree nodes; and a chromablock of the node A is not split, and corresponds to one chroma codingblock (which is a chroma CB for short). The N luma coding tree nodes maybe limited to no further split, or may be not limited. If a luma childnode continues to be split, a split mode of the luma child node parsed,to perform a recursive split. When a luma coding tree node is notfurther split, the luma coding tree node corresponds to a luma codingblock (which is a luma CB for short). A chroma transform blockcorresponding to a chroma CB and the chroma coding block have a samesize, and a chroma prediction block and the chroma coding block have asame size.

If an inter prediction mode is used for all the coding units in thecoverage area of the node A, the luma block and the chroma block of thenode A are further split into N coding tree nodes including a luma blockand a chroma block based on the split mode S, and the N coding treenodes may continue to be split or may be not split, and correspond tocoding units including a luma block and a chroma block.

Step 5: Parse prediction information and residual information of a CUobtained by splitting the node A.

The prediction information includes a prediction mode (indicating anintra prediction mode or a non-intra prediction mode), an intraprediction mode, an inter prediction mode, motion information, and thelike. The motion information may include information such as aprediction direction (forward, backward, or bidirectional), a referenceindex, and a motion vector.

The residual information includes a coded block flag (CBF), a transformcoefficient, a transform type (e.g., DCT-2, DST-7, DCT-8), and the like.The transform type may be DCT-2 by default.

If it is limited that only intra prediction can be performed on each CUobtained by splitting the node A, parsing of a prediction block of aluma CB obtained by splitting the node A includes: skip_flag,merge_flag, and cu_pred_mode are set respectively to 0, 0, and 1 (thatis, none of skip_flag, merge_flag, and cu_pred_mode are present in thebitstream), or skip_flag and cu_pred_mode are set respectively to 0 and1 by default (that is, none of skip_flag and cu_pred_mode are present inthe bitstream), and intra prediction mode information of the luma CB isparsed; parsing of a prediction block of a chroma CB obtained bysplitting the node A includes: parsing an intra prediction mode of thechroma CB. A method for parsing the intra prediction mode of the chromaCB may be: (1) parsing a syntax element from the bitstream to obtain theintra prediction mode of the chroma CB; and (2) directly setting theintra prediction mode of the chroma CB to one prediction mode in achroma intra prediction mode set, for example, one of a cross-componentlinear model mode, a DM mode (DM), or an IBC mode.

If it is limited that only inter prediction can be performed on each CUobtained by splitting the node A, parsing of a prediction mode of a CUobtained by splitting the node A includes: parsing skip_flag or/andmerge_flag, setting cu_pred_mode to 0 by default, and obtaining, throughparsing, an inter prediction block such as a merge index, an interprediction direction (inter dir), a reference index, a motion vectorpredictor index, and a motion vector difference.

A skip_flag is a flag representing a skip mode. When a value ofskip_flag is 1, it indicates that a skip mode is used for the currentCU; or when a value of skip_flag is 0, it indicates that no skip mode isused for the current CU. merge_flag is a flag representing a merge mode.When a value of merge_flag is 1, it indicates that a merge mode is usedfor the current CU; or when a value of merge_flag is 0, it indicatesthat no merge mode is used. cu_pred_mode is a flag representing aprediction mode of a coding unit. When a value of cu_pred_mode is 1, itindicates that intra prediction is performed on a current predictionunit; or when a value of cu_pred_mode is 0, it indicates that commoninter prediction is performed on a current prediction unit (informationsuch as an inter prediction direction, a reference index, a motionvector predictor index, and a motion vector difference component isidentified in the bitstream).

It should be noted that, in this embodiment, the intra prediction modeis a prediction mode for generating a predictor of a coding block byusing a spatial reference pixel of a picture in which the coding blockis located, for example, a direct current mode (DC mode), a planar mode,or an angular mode, or may include a template matching mode and an IBCmode.

The inter prediction mode is a prediction mode for generating apredictor of a coding block by using a temporal reference pixel in areference picture of the coding block, for example, a skip mode, a mergemode, an AMVP (advanced motion vector prediction) mode or a common Intermode, or an IBC mode.

Step 6: Decode each CU to obtain a reconstructed signal of a pictureblock corresponding to the node A.

For example, a prediction block of each CU performs inter predictionprocessing or intra prediction processing on the CU, to obtain an interpredicted picture or an intra predicted picture of the CU. Then,dequantization and inverse transform processing are performed on atransform coefficient based on residual information of each CU to obtaina residual picture, and the residual picture is superimposed on apredicted picture in a corresponding region to generate a reconstructedpicture.

According to the split mode in Embodiment 4, no small chroma block onwhich intra prediction is performed is generated, thereby resolvingproblems in intra prediction of small blocks.

Embodiment 5

Step 1, step 2, step 3, and step 6 in this embodiment are the same asthose in Embodiment 4.

Step 4: Determine a chroma block split mode and a luma block split modeof the node A.

A luma block of the node A continues to be split based on the split modeS, to generate N luma coding tree nodes. A chroma block of the node A isnot further split, and corresponds to one chroma coding block (chromaCB). A chroma transform block corresponding to a chroma CB and thechroma code block have a same size. [Note: Compared with Embodiment 4,in this embodiment, regardless of whether an inter prediction mode or anintra prediction mode is used is limited, the chroma block is always notsplit, and the luma block is always split based on the split mode Sregardless of a prediction mode for the coverage area of the node A.]

Step 5: Parse a prediction block and residual information of a CUobtained by splitting the node A.

If it is limited that only intra prediction can be performed on each CUobtained by splitting the node A, processing is the same as that inEmbodiment 4.

If it is limited that only inter prediction can be performed on each CUobtained by splitting the node A, parsing of a prediction mode of a lumaCB obtained by splitting the node A includes: parsing skip_flag or/andmerge_flag, setting cu_pred_mode to 0 by default, and obtaining, throughparsing, an inter prediction block such as a merge index, an interprediction direction (inter dir), a reference index, a motion vectorpredictor index, and a motion vector difference. Motion information ofeach 4×4 sub-block in the luma CB is derived from the inter predictionblock obtained through parsing.

If it is limited that only inter prediction can be performed on each CUobtained by splitting the node A, a prediction block of a chroma CBobtained by splitting the node A does not need to be parsed, and thechroma CB is split into 2×2 chroma sub-blocks (where a split mode may bethe split mode S). Motion information of each 2×2 chroma sub-lock ismotion information of a 4×4 luma region corresponding to the 2×2 chromasub-block.

According to the split mode in Embodiment 5, neither a small chromablock on which intra prediction is performed, nor a transform block lessthan 16 pixels is generated. Therefore, the foregoing problems in intraprediction and coefficient coding are resolved in Embodiment 5.

Embodiment 6

Step 1, step 2, step 3, step 4, and step 6 in this embodiment are thesame as those in Embodiment 5.

Step 5: Parse a prediction block and residual information of a CUobtained by splitting the node A.

If it is limited that only intra prediction can be performed on each CUobtained by splitting the node A, processing is the same as that inEmbodiment 5.

If it is limited that only inter prediction can be performed on each CUobtained by splitting the node A, parsing of a prediction block of aluma CB obtained by splitting the node A is the same as that inEmbodiment 5.

If it is limited that only inter prediction can be performed on each CUobtained by splitting the node A, a prediction block of a chroma CBobtained by splitting the node A does not need to be parsed, a chromaprediction block and a chroma coding block have a same size, and motioninformation of the chroma CB is motion information for a specific presetposition in a luma region corresponding to the chroma CB (e.g., thecenter, the bottom-right corner, or the top-left corner of the lumaregion).

According to the split mode in Embodiment 6, none of a small chromablock on which intra prediction is performed, a transform block of asmall block, and a small chroma block on which inter prediction isgenerated is generated.

Embodiment 7

Step 1: Step 1 is the same as step 1 in Embodiment 4.

Step 2: Determine whether a luma block of at least one child block B inchild nodes obtained by splitting the node A based on the split mode Sis a 4×4 luma block (whether the width, the height, and/or the splitmode of the node A, and/or the width and the height of a node B meet atleast one of conditions in case 1).

If a size (that is, the width and the height) of the node A and/or thesplit mode S meet/meets at least one of the conditions in case 1, it islimited that intra prediction is performed on all the coding units in acoverage area of the node A; otherwise, it is determined whether achroma block of at least one child node B in child nodes obtained bysplitting the node A based on the split mode S is a small block (whethera size and/or the split mode S of the node A, and/or the width and theheight of a node B meet at least one of conditions in case 2), if yes,step 3 to step 6 are performed.

Specifically, there are the following two cases for a method fordetermining that a chroma block of at least one child node B of the nodeA is a small block.

Case 1:

If one or more of the following preset conditions are true, the node Ais split based on the split mode S to obtain a 4×4 luma block:

(1) the node A includes M1 pixels, and the split mode of the node A is aquadtree split. For example, M1 is 64;

(2) the node A includes M2 pixels, and the split mode of the node A is aternary tree split. For example, M2 is 64;

(3) the node A includes M3 pixels, and the split mode of the node A is abinary tree split. For example, M3 is 32;

(4) the width of the node A is equal to four times a second threshold,the height of the node A is equal to the second threshold, and the splitmode of the node A is a vertical ternary tree split;

(5) the width of the node A is equal to a second threshold, the heightof the node A is equal to four times the second threshold, and the splitmode of the node A is a horizontal ternary tree split;

(6) the width of the node A is equal to twice a second threshold, theheight of the node A is equal to the second threshold, and the splitmode of the current node is a vertical binary split;

(7) the height of the node A is equal to twice a second threshold, thewidth of the node A is equal to the second threshold, and the split modeof the current node is a horizontal binary split; or

(8) the width or/and the height of the node A are/is twice a secondthreshold, and the split mode of the node A is a quadtree split.

The size may be the width and the height of a picture regioncorresponding to the node A, or a quantity of luma samples included in apicture region corresponding to the node A, or an area of a pictureregion corresponding to the node A.

Generally, the width of the current node is the width of the luma blockcorresponding to the current node, and the height of the current node isthe height of the luma block corresponding to the current node. In aspecific implementation, for example, the second threshold may be 4.

Case 2:

(1) a chroma block of at least one child node B of the node A has a sizeof a 2×4 or 4×2;

(2) the width or the height of a chroma block of at least one child nodeB of the node A is 2;

(3) the node A includes 128 luma samples and a ternary tree split isperformed on the node A, or the node A includes 64 luma samples and abinary tree split, a quadtree split, or a ternary tree split isperformed on the node A;

(4) the node A includes 256 luma samples and a ternary tree split or aquadtree split is performed on the node, or the node A includes 128 lumasamples and a binary tree split is performed on the node;

(5) the node A includes N1 luma samples and a ternary tree split isperformed on the node A, where N1 is 64, 128, or 256;

(6) the node A includes N2 luma samples and a quadtree split isperformed on the node A, where N2 is 64 or 256; or

(7) the node A includes N3 luma samples and a binary tree split isperformed on the node A, where N3 is 64, 128, or 256.

It should be noted that, that the node A includes 128 luma samples mayalso be described as that an area of the current node is 128, or aproduct of the width and the height of the node A is 128. Details arenot described herein.

Step 3: Step 3 is the same as step 3 in Embodiment 4.

Step 4: Determine a chroma block split mode and a luma block split modeof the node A based on a prediction mode used for the coding units inthe coverage area of the node A.

If an inter prediction mode is used for all the coding units in thecoverage area of the node A, a luma block and a chroma block of the nodeA are split based on the split mode S, to obtain child nodes of the nodeA and/or child nodes in the coverage area of the node A. If a 4×4 lumablock is generated based on a split mode of a child node of the node Aand/or a child node in the coverage area of the node A, the split modeof the child node is not allowed or the child node cannot continue to besplit. For example, if the node A has a size of 8×8 and two 8×4 (or two4×8) nodes are generated by splitting the node A in a horizontal binarytree split (or a vertical binary tree split) mode, the 8×4 (or 4×8) nodecontinues to be split into a 4×4 block; in this case, the 8×4 (or 4×8)node cannot continue to be split.

If an intra prediction mode is used for all the coding units in thecoverage area of the node A, the methods in Embodiments 4, 5, and 6 maybe used as implementation methods, and details are not described hereinagain. For example, the luma block of the node A is split, and thechroma block of the node A is not split.

Step 5: Parse a prediction block and residual information of a CUobtained by splitting the node A.

This step is the same as step 5 in Embodiment 4, and details are notdescribed herein again.

Step 6: Decode each CU to obtain a reconstructed signal of a pictureblock corresponding to the node A.

Step 6 may be implemented in a manner of step 6 in Embodiment 4, and isnot further described herein.

Embodiment 8

Step 1: Step 1 is the same as step 1 in Embodiment 4.

Step 2: Determine whether a luma block of at least one child block B inchild nodes obtained by splitting the node A based on the split mode Sis a 4×4 luma block (whether the width, the height, and/or the splitmode of the node A, and/or the width and the height of a node B meet atleast one of conditions in case 1). If a size (that is, the width andthe height) of the node A and/or the split mode S meet/meets at leastone of the conditions in case 1, it is limited that intra prediction isperformed on all the coding units in a coverage area of the node A; orit is determined whether a chroma block of at least one child node B inchild nodes obtained by splitting the node A based on the split mode Sis a small block (or whether a size and/or the split mode S of the nodeA, and/or the width and the height of the node B meet at least one ofconditions in case 2, step 3 to step 6 are performed.

Specifically, there are the following two cases for a method fordetermining that a chroma block of at least one child node B of the nodeA is a small block.

Case 1:

If one or more of the following preset conditions are true, the node Ais split based on the split mode S to obtain a 4×4 luma block:

(1) the node A includes M1 pixels, and the split mode of the node A is aquadtree split. For example, M1 is 64;

(2) the node A includes M2 pixels, and the split mode of the node A is aternary tree split. For example, M2 is 128;

(3) the node A includes M3 pixels, and the split mode of the node A is abinary tree split. For example, M3 is 32;

(4) the width of the node A is equal to four times a second threshold,the height of the node A is equal to the second threshold, and the splitmode of the node A is a vertical ternary tree split;

(5) the width of the node A is equal to a second threshold, the heightof the node A is equal to four times the second threshold, and the splitmode of the node A is a horizontal ternary tree split;

(6) the width of the node A is equal to twice a second threshold, theheight of the node A is equal to the second threshold, and the splitmode of the current node is a vertical binary split;

(7) the height of the node A is equal to twice a second threshold, thewidth of the node A is equal to the second threshold, and the split modeof the current node is a horizontal binary split; or

(8) the width or/and the height of the node A are/is twice a secondthreshold, and the split mode of the node A is a quadtree split.

The size may be the width and the height of a picture regioncorresponding to the node A, or a quantity of luma samples included in apicture region corresponding to the node A, or an area of a pictureregion corresponding to the node A.

Generally, the width of the current node is the width of the luma blockcorresponding to the current node, and the height of the current node isthe height of the luma block corresponding to the current node. In aspecific implementation, for example, the second threshold may be 4.

Case 2:

(1) a chroma block of at least one child node B of the node A has a sizeof a 2×4 or 4×2;

(2) the width or the height of a chroma block of at least one child nodeB of the node A is 2;

(3) the node A includes 128 luma samples and a ternary tree split isperformed on the node A, or the node A includes 64 luma samples and abinary tree split, a quadtree split, or a ternary tree split isperformed on the node A;

(4) the node A includes 256 luma samples and a ternary tree split or aquadtree split is performed on the node, or the node A includes 128 lumasamples and a binary tree split is performed on the node;

(5) the node A includes N1 luma samples and a ternary tree split isperformed on the node A, where N1 is 64, 128, or 256;

(6) the node A includes N2 luma samples and a quadtree split isperformed on the node A, where N2 is 64 or 256; or

(7) the node A includes N3 luma samples and a binary tree split isperformed on the node A, where N3 is 64, 128, or 256.

It should be noted that, that the node A includes 128 luma samples mayalso be described as that an area of the current node is 128, or aproduct of the width and the height of the node A is 128. Details arenot described herein.

Step 3: Step 3 is the same as step 3 in Embodiment 4.

Step 4: Determine a chroma block split mode and a luma block split modeof the node A based on a prediction mode used for the coding units inthe coverage area of the node A.

If an inter prediction mode is used for all the coding units in thecoverage area of the node A, a luma block and a chroma block of the nodeA are split based on the split mode S, to obtain child nodes of the nodeA and/or child nodes in the coverage area of the node A. If a 4×4 lumablock is generated based on a split mode of a child node of the node Aand/or a child node in the coverage area of the node A, the split modeof the child node is not allowed or the child node cannot continue to besplit. For example, if the node A has a size of 8×8 and two 8×4 (or two4×8) nodes are generated by splitting the node A in a horizontal binarytree split (or a vertical binary tree split) mode, the 8×4 (or 4×8) nodecontinues to be split into a 4×4 block; in this case, the 8×4 (or 4×8)node cannot continue to be split.

If an intra prediction mode is used for all the coding units in thecoverage area of the node A, the methods in Embodiments 4, 5, and 6 maybe used as implementation methods, and details are not described hereinagain. For example, the luma block of the node A is split, and thechroma block of the node A is not split.

Step 5: Parse a prediction block and residual information of a CUobtained by splitting the node A.

This step is the same as step 5 in Embodiment 4, and details are notdescribed herein again.

Step 6: Decode each CU to obtain a reconstructed signal of a pictureblock corresponding to the node A.

Step 6 may be implemented in a manner of step 6 in Embodiment 4, and isnot further described herein.

Embodiment 9

If a current region is split once to generate a 4×4 luma block (e.g., 64luma samples are split in a QT mode, or 128 luma samples are split in aTT mode), it is limited that only an intra mode can be used for thecurrent region by default; otherwise, a flag is transferred to indicatethat only an inter mode or only an intra mode can be used for thecurrent area.

If it is limited that only an inter mode can be used for the currentregion, luma and chroma are split jointly. If a node in the currentregion is split to generate a 4×4 luma block, this split is not allowed.For example, if the current node is 8×8 and is split in an HBT (or aVBT) mode to generate two 8×4 nodes. If these nodes continue to be splitto generate 4×4 CUs, these 8×4 nodes cannot continue to be split.

If it is limited that only an intra mode can be used for the region,this implementation is the same as the original implementation (luma issplit, but chroma is not split).

This illustrative example of the present invention provides a blocksplit method, to avoid that an intra prediction mode is used for achroma block with a comparatively small area, and facilitate pipelineprocessing of hardware and implementation of a decoder. In addition, ininter prediction, processes of parsing syntax elements for someprediction modes may be skipped, thereby reducing encoding complexity.

In this way, problems in coefficient coding are resolved, and codingcomplexity is reduced.

The block split method may be as follows:

A split mode of a node A is parsed.

It is determined whether a chroma block of at least one child node B isobtained as a small block after the node A is split based on the splitmode S. (It is determined whether the width, the height, and/or thesplit mode of the node A, and/or the width and the height of a node Bmeet at least one of the foregoing conditions.)

If it is determined that a chroma block of at least one child node B isobtained as a small block after the node A is split based on the splitmode S, an intra prediction mode or an inter prediction mode is used forall coding units in a coverage area of the node A.

It is determined whether to continue to split a chroma block and a lumablock of the node A.

If intra prediction is performed on all the coding units in the coveragearea of the node A, the luma block of the node A continues to be splitbased on the split mode S, and the chroma block of the node A is notfurther split. If inter prediction is performed on all the coding unitsin the coverage area of the node A, the luma block and the chroma blockof the node A continue to be split based on the split mode S into Ncoding tree nodes including a luma block and a chroma block.

The luma block of the node A continues to be split based on the splitmode S, and the chroma block of the node A is not further split. Achroma transform block and a chroma coding block have a same size.

When intra prediction is performed on all the coding units in thecoverage area of the node A, a chroma prediction block and the chromacoding block have a same size; or when inter prediction is performed onall the coding units in the coverage area of the node A, a chromaprediction block is split into sub-blocks (where the sub-blocks are lessthan the chroma coding block), and a motion vector of each sub-block isa motion vector in a luma region corresponding to the sub-block.

The luma block of the node A is further split based on the split mode S.The chroma block of the node A is not further split. A chroma transformblock corresponding to the chroma coding block and a chroma coding blockhave a same size, the chroma prediction block and the chroma codingblock have the same size, and motion information of the chroma CB ismotion information for a specific preset position in a luma regioncorresponding to the chroma CB.

Further illustrative examples of the present invention are provided inthe following. It should be noted that the numbering used in thefollowing section does not necessarily need to comply with the numberingused in the previous sections:

Embodiment 1. A picture partitioning method, comprising: determining asplit mode of a current node, wherein the current node comprises a lumablock and a chroma block; determining, based on the split mode of thecurrent node and a size of the current node, that the chroma block ofthe current node is not further split; and splitting the luma block ofthe current node based on the split mode of the current node.

Embodiment 2. The method according to embodiment 1, wherein thedetermining that the chroma block of the current node is not furthersplit comprises: when determining, based on the split mode of thecurrent node and the size of the current node, that a child nodegenerated by splitting the current node comprises a chroma block whoseside length is less than a threshold, the chroma block of the currentnode is not further split.

Embodiment 3. The method according to embodiment 1, wherein when a widthof the current node is equal to twice a threshold and the split mode ofthe current node is a vertical binary split, or when a height of thecurrent node is equal to twice a threshold and the split mode of thecurrent node is a horizontal binary split, or when a width of thecurrent node is equal to four times a threshold and the split mode ofthe current node is a vertical ternary split, or when a height of thecurrent node is equal to four times a threshold and the split mode ofthe current node is a horizontal ternary split, or when a width of thecurrent node is equal to twice a threshold and the split mode of thecurrent node is a quad split, the chroma block of the current node isnot further split.

Embodiment 4. The method according to any one of embodiments 1 to 3,wherein the luma block of the current node is split based on the splitmode of the current node, to obtain child nodes of the current node,wherein each child node comprises only a luma block.

Embodiment 5. The method according to embodiment 4, wherein the methodfurther comprises: parsing information of the luma block of the currentnode, to obtain prediction information and residual information of eachof sub-regions in the luma block, wherein the sub-regions one-to-onecorrespond to the child nodes.

Embodiment 6. The method according to embodiment 4 or 5, wherein thechild nodes are not further split by default, and each child nodecorresponds to one coding unit comprising only a luma block.

Embodiment 7. The method according to any one of embodiments 1 to 6,wherein the method further comprises: when the chroma block of thecurrent node is not further split, obtaining a prediction mode of thechroma block.

Embodiment 8. The method according to embodiment 7, wherein theprediction mode of the chroma block of the current node is determinedbased on a prediction mode of a luma block in a preset position of thecurrent node.

Embodiment 9. The method according to embodiment 8, wherein when theprediction mode used for the luma block in the preset position is aninter prediction mode, the inter prediction mode is used for the chromablock of the current node; or a first flag is parsed to determine theprediction mode of the chroma block based on the first flag.

Embodiment 10. The method according to embodiment 9, wherein when theinter prediction mode is used for the chroma block of the current node,motion information of the luma block in the preset position is obtainedas motion information of the chroma block; or the chroma block is splitinto chroma prediction sub-blocks, and motion information of the chromaprediction sub-blocks is obtained.

Embodiment 11. The method according to embodiment 9, wherein when it isdetermined, based on the first flag, that an intra prediction mode isused for the chroma block, an intra prediction mode is parsed from thebitstream and used as the intra prediction mode of the chroma block;when it is determined, based on the first flag, that the interprediction mode is used for the chroma block, motion information of theluma block in the preset position is obtained as motion information ofthe chroma block; or when it is determined, based on the first flag,that the inter prediction mode is used for the chroma block, the chromablock is split into chroma prediction sub-blocks, and motion informationof the chroma prediction sub-blocks is obtained.

Embodiment 12. The method according to embodiment 10 or 11, wherein thatmotion information of the chroma prediction sub-blocks is obtainedcomprises: if inter prediction is performed on luma blocks in lumapicture positions corresponding to the chroma prediction sub-blocks,motion information in the luma picture positions corresponding to thechroma prediction sub-blocks is used as the motion information of thechroma prediction sub-blocks; otherwise, motion information in thepreset position is used as the motion information of the chromaprediction sub-blocks.

Embodiment 13. The method according to embodiment 8, wherein when theprediction mode used for the luma block in the preset position is anintra prediction mode, the intra prediction mode is used for the chromablock of the current node.

Embodiment 14. The method according to embodiment 13, wherein an intraprediction mode is parsed from the bitstream as the intra predictionmode of the chroma block of the current node; or the intra predictionmode of the chroma block of the current node is one of a direct currentmode, a planar mode, an angular mode, a cross-component linear modelmode, or a chroma derived DM mode.

Embodiment 15. The method according to embodiment 8, wherein when theprediction mode used for the luma block in the preset position is anintra block copy (IBC) mode, the IBC prediction mode is used for thechroma block of the current node; or a second flag is parsed todetermine the prediction mode of the chroma block based on the secondflag.

Embodiment 16. The method according to embodiment 15, wherein when theIBC prediction mode is used for the chroma block of the current node,the method further comprises: obtaining displacement vector informationof the luma block in the preset position as displacement vectorinformation of the chroma block of the current node.

Embodiment 17. The method according to embodiment 15, wherein the IBCmode is used for the chroma block if a value of the second flag is afirst value; an intra prediction mode is used for the chroma block if avalue of the second flag is a first value; or an inter prediction modeis used for the chroma block if a value of the second flag is a secondvalue.

Embodiment 18. The method according to embodiment 7, wherein the methodfurther comprises: obtaining a prediction mode of a plurality of lumablocks obtained through splitting; and determining the prediction modeof the chroma block of the current node based on the prediction mode ofthe plurality of luma blocks obtained through splitting.

Embodiment 19. The method according to embodiment 18, wherein when theprediction mode used for the plurality of luma blocks is an intraprediction mode, the intra prediction mode is used for the chroma blockof the current node.

Embodiment 20. The method according to embodiment 18, wherein when theprediction mode used for the plurality of luma blocks is an interprediction mode, motion information of a luma block in a preset positionis used as motion information of the chroma block of the current nodewhen the inter prediction mode is used for the chroma block of thecurrent node; or when the prediction mode used for the plurality of lumablocks is an inter prediction mode, a first flag is parsed to determinethe prediction mode of the chroma block based on the first flag.

Embodiment 21. The method according to embodiment 20, wherein when it isdetermined, based on the first flag, that an intra prediction mode isused for the chroma block, an intra prediction mode is parsed from thebitstream and used as the intra prediction mode of the chroma block; orwhen it is determined, based on the first flag, that the interprediction mode is used for the chroma block, motion information of aluma block in a preset position is obtained as motion information of thechroma block.

Embodiment 22. The method according to embodiment 18, wherein when theprediction mode used for the plurality of luma blocks comprises an interprediction mode and an intra prediction mode, a prediction mode of aluma block in a preset position of the current node is obtained as theprediction mode of the chroma block of the current node.

Embodiment 23. The method according to any one of embodiments 1 to 22,wherein if the current node is an I-frame, the intra prediction mode isused for each child node of the current node; or if the current node isa P-frame or a B-frame, a first child node is parsed to obtain aprediction mode of the first child node, wherein a prediction mode ofremaining child nodes is the same as the prediction mode of the firstchild node, and the first child node is a node that is first parsed.

Embodiment 24. The method according to any one of embodiments 1 to 22,wherein if the current node is an I-frame, the intra prediction mode isused for each child node of the current node; or if the current node isa P-frame or a B-frame, the inter prediction mode is used for each childnode of the current node.

Embodiment 25. The method according to any one of embodiments 1 to 24,wherein determining, based on the split mode of the current node, thesize of the current node, and the prediction mode of a first child nodeof the current node, that the chroma block of the current node is notfurther split, wherein the first child node comprises only a luma block,and the first child node is the node that is first parsed.

Embodiment 26. The method according to embodiment 25, whereindetermining, based on the split mode of the current node and the size ofthe current node, that the child node generated by splitting the currentnode comprises a chroma block whose side length is less than athreshold, and the prediction mode of the first child node is the intraprediction mode, the chroma block of the current node is not furthersplit.

Embodiment 27. The method according to embodiment 26, wherein when theprediction mode of the first child node is intra prediction and any oneof the following conditions is true: when the width of the current nodeis equal to twice the threshold and the split mode of the current nodeis the vertical binary split, or when the height of the current node isequal to twice the threshold and the split mode of the current node isthe horizontal binary split, or when the width of the current node isequal to four times the threshold and the split mode of the current nodeis the vertical ternary split, or when the height of the current node isequal to four times the threshold and the split mode of the current nodeis the horizontal ternary split, or when the width of the current nodeis equal to twice the threshold and the split mode of the current nodeis the quad split, the chroma block of the current node is not furthersplit.

Embodiment 28. The method according to any one of embodiments 1 to 24,wherein determining, based on the split mode of the current node and thesize of the current node, that the child node generated by splitting thecurrent node comprises the chroma block whose side length is less thanthe threshold; if the prediction mode of a first child node is interprediction, the chroma block of the current node is split based on thesplit mode of the current node, wherein the first child node is a nodethat is first parsed.

Embodiment 29. The method according to embodiment 28, wherein the methodfurther comprises: determining motion information of a correspondingchild node of the chroma block based on motion information of the childnodes of the current node.

For example, it should be understood that disclosed content withreference to a described method may also hold true for a correspondingdevice or system configured to perform the method and vice versa. Forexample, if one or more specific method steps are described, acorresponding device may include one or more units such as functionalunits, to perform the described one or more method steps (e.g., one unitperforming the one or more steps; or a plurality of units eachperforming one or more of the plurality of steps), even if such one ormore units are not explicitly described or illustrated in theaccompanying drawings. In addition, for example, if a specific apparatusis described based on one or more units such as functional units, acorresponding method may include one step to perform functionality ofone or more units (e.g., one step to perform the functionality of theone or more units, or a plurality of steps each of which is used toperform the functionality of one or more of the plurality of units),even if such one or more steps are not explicitly described orillustrated in the accompanying drawings. Further, it should beunderstood that features of the example embodiments and/or aspectsdescribed in this specification may be combined with each other, unlessspecifically noted otherwise.

In one or more examples, the described functions may be implemented byhardware, software, firmware, or any combination thereof. If implementedin software, the functions may be stored on or transmitted over as oneor more instructions or code on a computer-readable medium and executedby a hardware-based processing unit. Computer-readable media may includecomputer-readable storage media, which corresponds to a tangible mediumsuch as data storage media, or communication media including any mediumthat facilitates transfer of a computer program from one place toanother, for example, according to a communication protocol. In thismanner, the computer-readable medium may usually correspond to (1)non-transitory tangible computer-readable storage media or (2) acommunication medium such as a signal or carrier wave. The data storagemedium may be any available medium that can be accessed by one or morecomputers or one or more processors to retrieve instructions, code,and/or data structures for implementation of the technologies describedin the present disclosure. A computer program product may include acomputer-readable medium.

By way of example but not limitation, such type of computer-readablestorage media can include a RAM, a ROM, an EEPROM, a CD-ROM or anotheroptical disk storage, a magnetic disk storage or another magneticstorage device, a flash memory, or any other medium that can be used tostore desired program code in a form of instructions or data structuresand that can be accessed by a computer. In addition, any connection isappropriately referred to as a computer-readable medium. For example, ifinstructions are transmitted from a website, server, or another remotesource by using a coaxial cable, a fiber optic cable, a twisted pair, adigital subscriber line (DSL), or wireless technologies such asinfrared, radio, and microwave, the coaxial cable, the fiber opticcable, the twisted pair, the DSL, or the wireless technologies such asinfrared, radio, and microwave are included in a definition of medium.However, it should be understood that computer-readable storage mediumand the data storage medium do not include a connection, a carrier wave,a signal, or another transitory medium, but are actually directed tonon-transitory tangible storage media. As used in this specification, adisk and an optical disc include a compact disc (CD), a laser disc, anoptical disc, a digital versatile disc (DVD), a soft disk, and a Blu-raydisc. The disk generally reproduces data magnetically, while the opticaldisc reproduces the data optically with a laser. A combination of theabove should also be included within the scope of the computer-readablemedia.

The instructions may be executed by one or more processors, such as oneor more digital signal processors (DSP), general purposemicroprocessors, application-specific integrated circuits (ASIC), fieldprogrammable logic arrays (FPGA), or other equivalent integrated ordiscrete logic circuitry. Therefore, the term “processor” used in thisspecification may represent any one of the foregoing structures oranother structure that is applicable to implement the technologiesdescribed in this specification. In addition, in some aspects, thefunctionality described in this specification may be provided withindedicated hardware and/or software modules configured for encoding anddecoding, or incorporated in a combined codec. In addition, thetechnologies may be all implemented in one or more circuits or logicelements.

The technologies of this disclosure may be implemented in a wide varietyof devices or apparatuses, including a wireless handset, an integratedcircuit (IC) or a set of ICs (e.g., a chip set). Various components,modules, or units are described in this disclosure to emphasizefunctional aspects of devices configured to perform the disclosedtechnologies, but do not necessarily require achievement by differenthardware units. Exactly, as described above, the units may be combinedin a codec hardware unit or provided by a collection of interoperativehardware units including one or more processors as described above, inconjunction with appropriate software and/or firmware.

1. A picture partitioning method, comprising: determining a split modeof a current node that comprises a luma block and a chroma block;determining, based on the split mode of the current node and a size ofthe current node, that the chroma block of the current node is notfurther split; and splitting, based on the split mode of the currentnode, the luma block of the current node; wherein the chroma block ofthe current node is not further split in accordance with one or moredeterminations taken from the group consisting of: a width of thecurrent node is equal to twice a threshold and the split mode of thecurrent node is a vertical binary split, a height of the current node isequal to twice a threshold and the split mode of the current node is ahorizontal binary split, a width of the current node is equal to fourtimes a threshold and the split mode of the current node is a verticalternary split, a height of the current node is equal to four times athreshold and the split mode of the current node is a horizontal ternarysplit, and a width of the current node is equal to twice a threshold andthe split mode of the current node is a quad split.
 2. The methodaccording to claim 1, wherein the chroma block of the current node isnot further split in accordance with determining, based on the splitmode of the current node and the size of the current node, that a childnode generated by splitting the current node comprises a child chromablock whose side length is less than the threshold.
 3. The methodaccording to claim 1, wherein the chroma block of the current node isnot further split in accordance with determining, based on the splitmode of the current node and the size of the current node, that a childnode generated by splitting the current node comprises a child chromablock whose size is less than
 16. 4. The method according to claim 1,wherein the threshold is
 4. 5. The method according to claim 1, whereinwhether the chroma block of the current node needs to be split isdetermined based on the split mode of the current node, the size of thecurrent node, and a node prediction mode identifier.
 6. The methodaccording to claim 1, wherein the current node belongs to an I slice,and wherein the chroma block of the current node is not further split inaccordance with one or more determinations taken from the groupconsisting of: a product of a width and a height of the current node isequal to 64 and the split mode of the current node is a binary treesplit, and a product of a width and a height of the current node isequal to 128 and the split mode of the current node is a ternary treesplit.
 7. The method according to claim 1, wherein the current nodebelongs to a P or B slice, and wherein the chroma block of the currentnode is not further split in accordance with one or more determinationstaken from the group consisting of: the product of the width and theheight of the current node is equal to 64 and the split mode of thecurrent node is the binary tree split, and the product of the width andthe height of the current node is equal to 128 and the split mode of thecurrent node is the ternary tree split, and a node prediction modeidentifier indicates that no inter prediction is performed on a codingblock obtained by splitting the current node.
 8. The method according toclaim 1, wherein the chroma block of the current node is not furthersplit in accordance with one or more determinations taken from the groupconsisting of: a product of the width and the height of the current nodeis less than 128 and the split mode of the current node is a verticalbinary split or a horizontal binary split; a product of the width andthe height of the current node is less than 256 and the split mode ofthe current node is a vertical ternary split, a horizontal ternarysplit, or a quad split; a product of the width and the height of thecurrent node is equal to 64 and the split mode of the current node is avertical binary split, a horizontal binary split, a quad split, ahorizontal ternary split, or a vertical ternary split; and a product ofthe width and the height of the current node is equal to 128 and thesplit mode of the current node is a vertical ternary split or ahorizontal ternary split.
 9. The method according to claim 1, whereindetermining, based on a data format of the current node, the split modeof the current node, and the size of the current node, whether thechroma block of the current node is further split, wherein the dataformat of the current node is YUV4:2:0 or YUV4:2:2.
 10. A video streamcoding apparatus, comprising: a non-transitory computer-readable storagemedium storing instructions; and one or more processors in communicationwith the medium and upon execution of the instructions, configured to:determine a split mode of a current node that comprises a luma block anda chroma block; determine, based on the split mode of the current nodeand a size of the current node, that the chroma block of the currentnode is not further split; and split, based on the split mode of thecurrent node, the luma block of the current node, wherein the chromablock of the current node is not further split in accordance with one ormore determinations taken from the group consisting of: a width of thecurrent node is equal to twice a threshold and the split mode of thecurrent node is a vertical binary split, a height of the current node isequal to twice a threshold and the split mode of the current node is ahorizontal binary split, a width of the current node is equal to fourtimes a threshold and the split mode of the current node is a verticalternary split, a height of the current node is equal to four times athreshold and the split mode of the current node is a horizontal ternarysplit, and a width of the current node is equal to twice a threshold andthe split mode of the current node is a quad split.
 11. The apparatusaccording to claim 10, wherein the chroma block of the current node isnot further split in case that determining, based on the split mode ofthe current node and the size of the current node, that a child nodegenerated by splitting the current node comprises a child chroma blockwhose side length is less than the threshold.
 12. The apparatusaccording to claim 10, wherein the chroma block of the current node isnot further split in case that determining, based on the split mode ofthe current node and the size of the current node, that a child nodegenerated by splitting the current node comprises a child chroma blockwhose size is less than
 16. 13. The apparatus according to claim 10,wherein the threshold is
 4. 14. The apparatus according to claim 10,wherein whether the chroma block of the current node needs to be splitis determined based on the split mode of the current node, the size ofthe current node, and a node prediction mode identifier.
 15. Theapparatus according to claim 10, wherein the current node belongs to anI slice, and wherein the chroma block of the current node is not furthersplit in accordance with one or more determinations taken from the groupconsisting of: a product of a width and a height of the current node isequal to 64 and the split mode of the current node is a binary treesplit, and a product of a width and a height of the current node isequal to 128 and the split mode of the current node is a ternary treesplit.
 16. The apparatus according to claim 10, wherein the current nodebelongs to a P or B slice, and wherein the chroma block of the currentnode is not further split in accordance with one or more determinationstaken from the group consisting of: the product of the width and theheight of the current node is equal to 64 and the split mode of thecurrent node is the binary tree split, and the product of the width andthe height of the current node is equal to 128 and the split mode of thecurrent node is the ternary tree split, and a node prediction modeidentifier indicates that no inter prediction is performed on a codingblock obtained by splitting the current node.
 17. The apparatusaccording to claim 10, wherein the chroma block of the current node isnot further split in accordance with one or more determinations takenfrom the group consisting of: a product of the width and the height ofthe current node is less than 128 and the split mode of the current nodeis a vertical binary split or a horizontal binary split; or a product ofthe width and the height of the current node is less than 256 and thesplit mode of the current node is a vertical ternary split, a horizontalternary split, or a quad split; when a product of the width and theheight of the current node is equal to 64 and the split mode of thecurrent node is a vertical binary split, a horizontal binary split, aquad split, a horizontal ternary split, or a vertical ternary split; anda product of the width and the height of the current node is equal to128 and the split mode of the current node is a vertical ternary splitor a horizontal ternary split.
 18. The apparatus according to claim 10,wherein determining, based on a data format of the current node, thesplit mode of the current node, and the size of the current node,whether the chroma block of the current node is further split, whereinthe data format of the current node is YUV4:2:0 or YUV4:2:2.
 19. Anon-transitory computer-readable storage medium comprising a bitstreamdecoded by performing the operations of: determining a split mode of acurrent node that comprises a luma block and a chroma block;determining, based on the split mode of the current node and a size ofthe current node, that the chroma block of the current node is notfurther split; and splitting, based on the split mode of the currentnode, the luma block of the current node; wherein the chroma block ofthe current node is not further split in accordance with one or moredeterminations taken from the group consisting of: a width of thecurrent node is equal to twice a threshold and the split mode of thecurrent node is a vertical binary split, a height of the current node isequal to twice a threshold and the split mode of the current node is ahorizontal binary split, a width of the current node is equal to fourtimes a threshold and the split mode of the current node is a verticalternary split, a height of the current node is equal to four times athreshold and the split mode of the current node is a horizontal ternarysplit, and a width of the current node is equal to twice a threshold andthe split mode of the current node is a quad split.